Quantcast
Channel: UNIX and Linux Forums
Browsing all 16232 articles
Browse latest View live

Ps command output confusing

Hi, I ran a script named cat item when I searched for this script using command Code: PS I get two process . I don't understand this. Also this script has run for 15 minutes but the time is showing as...

View Article


Need help in solving to obtain desired print output using awk or perl or any...

I have an file which have data in lines as follows Code: ad, findline=24,an=54,ab=34,av=64,ab=7989,ab65=34,aj=323,ay=34,au=545,ad=5545...

View Article


Continue command in shell script

Hi, I have following code in linux script. Code: if [ -L /tmp/file/test]            # remove symbolic linked files in etcld     then         bin/unlink /tmp/file/test  # unlink file so it doesn't get...

View Article

Is CRON is only for root user

Hi, i have question about cron. can we have user based cron file under /var/spool/cron or we should have only root file which can only be accessed by root user or admin and he should only be doing the...

View Article

GlusterFS

Hi, I want to share storage using glusterfs. I follow tutorial as below: https://www.howtoforge.com/how-to-in...n-ubuntu-14.04 But why size not same as i mount from lvm? Code: [root@localhost...

View Article


Script with ping

I have a question is there any posibility for writing a script that you can see if a pc in your network is up of down , when you run this script for ex. ./test.sh 63 45 54 , which are the ip adresses...

View Article

Problems with past arguments in script

I have a question is there any possibility for maken a script that you can see if computers are on in your network when you run the script for ex. ./ping.sh 54 62 62 , a script when you give as...

View Article

Replace C instructions for system calls

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: Modify the program...

View Article


Running a KSH file from VPS on Godaddy

i have looked for a week and tried a few things, but nothing seems to work so joined here. I have a go daddy account and also a vps in germany. In my vps, i run a code script (we will call it codegen)...

View Article


Finiding Files with Perl or awk?

I posted last week about how the find command (known to be slow to begin with), is slowing down by 75x on a windows remote share. Do awk or Perl have the capability to find files (pretty sure the...

View Article

Parallel replacement string

Hi, Using the following command, I can only get rid of the last extension from my input file name: Code: parallel command '>' {.}.output ::: my.input.file The output file is " Code: my.input.output...

View Article

Infinite "while" loop subshell loses current date variable

I have a simple script to log network connectivity to a set of systems. However, as expected the date appended to the log never changes because the new variable is lost when the loop starts again. Can...

View Article

Script to automate recovery process

Hello All! First post... I am working on a script that is used to recover a crashed drive from an rsync backup. I'm down to the place where I need to create all of the directories in /mnt where I will...

View Article


Count occurrences in first column

input Code: amex-11        10        abc amex-11        20        bcn amed-12        1        abc I tried something like this. Code: awk '{h[$1]++}; END { for(k in h) print k, h[k] }' rm1 output Code:...

View Article

Need to strip control-A characters from a column in a file

Hi All, I currently have flat file with 32 columns. The field delimiter is cntl-A ( \x01). The file has been extracted from an oracle table using a datastage job. However, in the 6th field, the data...

View Article


FYI - gotcha when using a nawk one liner to convert a processes RSS to MB

I used the following one liner (obtained from an old thread on this site) to look for RSS size of a process and convert it to Mb (I am using process nfsmapid as an example): Code: ps -eo rss,args |...

View Article

How to copy file from windowm to AIX using scp command?

Hi I'd like to copy file ( or directory ) from a window server to an unix server using scp command, something like this Code: scp -rp admin@10.0.99.99:C:\Documents and Settings\abc.txt...

View Article


Solaris 10 32bit installation

Hi sorry for the novice question. i need to install Solaris 10 32bit version. i downloaded the ISO from oracle website. as i understand the same ISO is for the 64bit as well as the 32bit install??? i...

View Article

Simple looping in shell

Hii all. I have a problem with my shell script. This is my code Code: while [ $count -le 13526 ] do     space.exe inputs/gr$count >> outputs/t$count     count=$[$count+1] done I ussually work in...

View Article

Shell script doubt in special character

when I execute the unix commands its works normally in the 1st part. When I the tried the same in shell scripting the directory is not displayed in 2nd part example. please let me know what needs to be...

View Article
Browsing all 16232 articles
Browse latest View live