Hi im new to unix and need to find a way to grep the top 5 numbers in a file and put them into another file. For example my file looks like this
abcdef 50000
abcdef 45000
abcdef 40000
abcdef 35000
abcdef 30000
abcdef 25000
abcdef 20000
abcdef 15000
abcdef 10000
and so on...
How can... (1 Reply)
I have a text file in the following format
....
START
1,1
2,1
3,1
..
..
9,1
10,1
END
....
I want to change to the output to
....
START
1,1
2,1
3,1
.. (4 Replies)
I am trying to add free and used memory (so that i can compute percentage used)of remote nodes using shell script. I use the openssh-server,expect tool and ssh script.
1)login.txt (info of nodes):
ip1|username|password
ip2|username|password
.
.
.
3)sshlogin.sh
#!/bin/bash ... (1 Reply)
Hello,
I have a column where there are values from 1 to 150.
I want to get the frequency of values in the following ranges:
1-5
6-10
11-15
....
....
....
146-150
How can I do this in a for loop?
Thanks,
Guss (1 Reply)
Hello All,
I am having problem to find what is the smallest number from 90% of highest numbers from all numbers in file. I am having file with thousands of lines and hundreds of columns.
I am familiar mainly with bash but I am open to whatever suggestion witch will lead to the solutions.
If I... (11 Replies)
I am trying to make a script to read marks from a file then find out how many of them are above 40 (passing marks). However my script is getting stuck at "read num". I dont understand whats the problem. Any help will be much appreciated.
#!/bin/bash
set -x
count=0; countP=0; PASSMK=40... (6 Replies)
Hi,
I'm trying to match a filename that could be called anything from vout001 to vout252 and was trying to do a small test but I'm not getting the result I thought I would..
Can some one tell me what I'm doing wrong?
*****@********>echo $mynumber ... (4 Replies)
Hi again. Sorry for all the questions — I've tried to do all this myself but I'm just not good enough yet, and the help I've received so far from bartus11 has been absolutely invaluable. Hopefully this will be the last bit of file manipulation I need to do.
I have a file which is formatted as... (4 Replies)
Hello,
I have the following script
while read id fraction
do
sambamba -h -f bam -t 10 --subsampling-seed=50 -s $frac ${id}.bam -o ${id}.out.bam
done < fraction.txt
where fraction.txt has two columns (id,fraction) and 50 rows
I am unable to run this as bash is not able to read the second... (2 Replies)
Discussion started by: nans
2 Replies
LEARN ABOUT FREEBSD
dwarf_get_dsc_name
DWARF_GET_AT_NAME(3) BSD Library Functions Manual DWARF_GET_AT_NAME(3)NAME
dwarf_get_ACCESS_name, dwarf_get_AT_name, dwarf_get_ATE_name, dwarf_get_CC_name, dwarf_get_CFA_name, dwarf_get_CHILDREN_name,
dwarf_get_DS_name, dwarf_get_DSC_name, dwarf_get_EH_name, dwarf_get_END_name, dwarf_get_FORM_name, dwarf_get_ID_name, dwarf_get_INL_name,
dwarf_get_LANG_name, dwarf_get_LNE_name, dwarf_get_LNS_name, dwarf_get_MACINFO_name, dwarf_get_OP_name, dwarf_get_ORD_name,
dwarf_get_TAG_name, dwarf_get_VIRTUALITY_name, dwarf_get_VIS_name -- retrieve the symbolic names of DWARF constants
LIBRARY
DWARF Access Library (libdwarf, -ldwarf)
SYNOPSIS
#include <libdwarf.h>
int
dwarf_get_ACCESS_name(unsigned val, char **str);
int
dwarf_get_AT_name(unsigned val, char **str);
int
dwarf_get_ATE_name(unsigned val, char **str);
int
dwarf_get_CC_name(unsigned val, char **str);
int
dwarf_get_CFA_name(unsigned val, char **str);
int
dwarf_get_CHILDREN_name(unsigned val, char **str);
int
dwarf_get_DS_name(unsigned val, char **str);
int
dwarf_get_DSC_name(unsigned val, char **str);
int
dwarf_get_EH_name(unsigned val, char **str);
int
dwarf_get_END_name(unsigned val, char **str);
int
dwarf_get_FORM_name(unsigned val, char **str);
int
dwarf_get_ID_name(unsigned val, char **str);
int
dwarf_get_INL_name(unsigned val, char **str);
int
dwarf_get_LANG_name(unsigned val, char **str);
int
dwarf_get_LNE_name(unsigned val, char **str);
int
dwarf_get_LNS_name(unsigned val, char **str);
int
dwarf_get_MACINFO_name(unsigned val, char **str);
int
dwarf_get_OP_name(unsigned val, char **str);
int
dwarf_get_ORD_name(unsigned val, char **str);
int
dwarf_get_TAG_name(unsigned val, char **str);
int
dwarf_get_VIRTUALITY_name(unsigned val, char **str);
int
dwarf_get_VIS_name(unsigned val, char **str);
DESCRIPTION
These functions return the symbolic name of a numeric DWARF constant.
Argument val specifies the numeric value whose symbolic name is desired.
Argument str should point to a location which will hold the returned NUL-terminated string containing the symbolic name of the specified
value.
The list of functions and the DWARF constants that they accept are:
dwarf_get_ACCESS_name() DW_ACCESS_* constants.
dwarf_get_AT_name() DW_AT_* constants.
dwarf_get_ATE_name() DW_ATE_* constants.
dwarf_get_CC_name() DW_CC_* constants.
dwarf_get_CFA_name() DW_CFA_* constants.
dwarf_get_CHILDREN_name() DW_CHILDREN_* constants.
dwarf_get_DS_name() DW_DS_* constants.
dwarf_get_DSC_name() DW_DSC_* constants.
dwarf_get_EH_name() DW_EH_PE_* constants.
dwarf_get_END_name() DW_END_* constants.
dwarf_get_FORM_name() DW_FORM_* constants.
dwarf_get_ID_name() DW_ID_* constants.
dwarf_get_INL_name() DW_INL_* constants.
dwarf_get_LANG_name() DW_LANG_* constants.
dwarf_get_LNE_name() DW_LNE_* constants.
dwarf_get_LNS_name() DW_LNS_* constants.
dwarf_get_MACINFO_name() DW_MACINFO_* constants.
dwarf_get_OP_name() DW_OP_* constants.
dwarf_get_ORD_name() DW_ORD_* constants.
dwarf_get_TAG_name() DW_TAG_* constants.
dwarf_get_VIRTUALITY_name() DW_VIRTUALITY_* constants.
dwarf_get_VIS_name() DW_VIS_* constants.
RETURN VALUES
These functions return DW_DLV_OK on success. If the DWARF constant denoted by argument val is not recognized, these function return
DW_DLV_NO_ENTRY.
SEE ALSO dwarf(3)BSD April 22, 2011 BSD