Search Results

Search: Posts Made By: sam_bd
795
Posted By sam_bd
Help with tar cmd for directories
Hi, I'm working on HP-UX B.11.23 64bit. I tried to tar couple of directories but failed to do so.
$ tar -cvf tar_file_name -C /dir1 /dir2

the -C is for directories as mentioned in the man pages....
2,122
Posted By sam_bd
MadeInGermany: Thanks. I'm getting output in...
MadeInGermany: Thanks. I'm getting output in output.txt. I totally forgot about it. In the code i included
done < ${SERVERLIST} > ${OUTPUTLIST} 2> /dev/null
which's suppressing the HP UX banners &...
2,122
Posted By sam_bd
Thank you vbe, MadeInGermany for your responses. ...
Thank you vbe, MadeInGermany for your responses.
vbe: yes i'll keep that in mind not to use keywords.
MadeInGermany: i did type ssh and got ssh is /usr/bin/ssh. I ran the script without using the...
2,122
Posted By sam_bd
Thank you very much RudiC and MadeInGermany for...
Thank you very much RudiC and MadeInGermany for your inputs. I'm getting below error when i used while loop as mentioned above;
Pseudo-terminal will not be allocated because stdin is not a terminal....
2,122
Posted By sam_bd
Error with script for ssh
Hi,
I'm getting error while getting output of home directories for multiple servers. Could anyone please help; (using HP-UX; shell=ksh)


SERVERLIST=serverlist.txt
OUTPUTLIST=output.txt
...
1,589
Posted By sam_bd
Yes. This break-up explanation of the code you...
Yes. This break-up explanation of the code you gave really helping me. I'm introduced to new form of awk esp. next command, placing current search value in a variable & later printing with the second...
1,589
Posted By sam_bd
Thanks R.Singh. awk -F"=" '/SName/{VAL=$0;next}...
Thanks R.Singh. awk -F"=" '/SName/{VAL=$0;next} /ESys/{print VAL,$0}' Input_file This code looks to be working on my first try. Input file is just what i've mentioned in my first question post. In...
1,589
Posted By sam_bd
Tried with awk '/SName/ || /ESys/' Input_file ...
Tried with awk '/SName/ || /ESys/' Input_file
but not getting output as expected. i need output in following manner:
SName=abc123 ESys=xyz456
SName=cdf234 ESys=gfh768
SName=rfg346 ...
1,589
Posted By sam_bd
Multi pattern selection
I'm confused with what to use (awk or grep) in this case as i need to select 2 corresponding patterns. "SName" & "ESys" in a appln config file which looks like this;

[appln name1]
SName=abc123...
2,619
Posted By sam_bd
I'm on HP-UX B.11.23. Amazed to see the function...
I'm on HP-UX B.11.23. Amazed to see the function of awk in this case & realized output of ps command is also a data in tabular format which awk deals with. Need to dig deeper in awk.
2,619
Posted By sam_bd
sorry for delay. Ravinder: yes, your suggested...
sorry for delay. Ravinder: yes, your suggested code did work; Thank you.
M.i.Germany: ps -eaf | grep '[A]pplnName' | awk 'index($0,"/opt/xxx/yyy")' worked for me. Thank you.
RudiC: your suggestion...
2,619
Posted By sam_bd
Filesystem pattern match in awk
Hi, I'm trying to grep appln processes using its filesystem and also using awk to get accurate results, however when i'm uisng the filesystem in awk statement i'm getting error. Requesting help.

...
2,065
Posted By sam_bd
RudiC: if i login interactively i do get tabular...
RudiC: if i login interactively i do get tabular format of output for who command. i guess some OS level things are reasons for this. Now, i'm not getting any output at all. SSH does work (getting HP...
2,065
Posted By sam_bd
cero: Yes. I'm trying with one server (OS: HP-UX...
cero: Yes. I'm trying with one server (OS: HP-UX Server1 B.11.23) and next want to include few others in the cluster. Need few other reporting from those chosen server of which output of 'who'...
2,065
Posted By sam_bd
$ ssh user1@serverxx 'who' output: XXXX pts/0...
$ ssh user1@serverxx 'who'
output:
XXXX pts/0 Oct 18 08:45 abcd pts/3 Oct 18 06:46 abcde pts/4 Oct 18 06:46 xyzqw pts/5 Oct 18 07:32 qwert pts/6 Oct 18 07:32 asdf pts/7 Oct 18 07:32
2,065
Posted By sam_bd
Oh!..sorry was some confusion. Well here is it: ...
Oh!..sorry was some confusion. Well here is it:
I did ssh from one server to another server with 'who' command which produced this result.
XXXX pts/0 Oct 18 08:45 abcd pts/3 Oct 18 06:46 abcde...
2,065
Posted By sam_bd
RudiC, i'm still facing same problem of getting...
RudiC, i'm still facing same problem of getting the output in single line instead of getting it in tabular format. Any suggestion would be of great help. Thanks.
2,065
Posted By sam_bd
Thanks for the response RudiC. When i included...
Thanks for the response RudiC. When i included few servers to collect info this was the output for one of the servers which had more than 2 users to be listed with 'who' command.
Otherwise, for a...
2,065
Posted By sam_bd
Ssh output
Hi, I need to get the output of ssh for multiple servers using for loop which is returning how many users are logged in, one below the other. But i'm getting output in single line for one of the...
937
Posted By sam_bd
Longlist files without expanding
Hi, I want to long list files within a file.tar.Z/file.tar.gz file. I tried these:
I'm working on HP UX 11iV3 OS

tar -tvzf file.tar.gz -->not working as 'z' is not supported
gunzip -c...
817
Posted By sam_bd
RudiC, Don C, saps19 Thanks each one of you. I...
RudiC, Don C, saps19 Thanks each one of you. I did try looking at your posts. This is good learning for me. Thanks indeed for giving direction to think.

...
817
Posted By sam_bd
Thanks for your reply RudiC. I just tried with...
Thanks for your reply RudiC. I just tried with do-while loop.

#!/bin/ksh
while read i
do
ls -lrt $i
done < files.txt


I'm getting desired output of long listing of files via "ls -lrt"...
817
Posted By sam_bd
For or while?
Hi, I've a file containing file names along with their path. I need a script which checks each line in that file which has file names along with their path and display if a particular file exists or...
9,307
Posted By sam_bd
Airlines industry
Hi, I want to move to unix admin from support. Which unix can i learn to get into airlines industry projects? Thanks in advance.
861
Posted By sam_bd
Perl-extraction using windows cmd
Hi, I need to extract Password expires from the output of windows command print `net user %USERNAME% /domain`; in perl. So i want to redirect the output of this win-cmd to a file and try extracting...
Showing results 1 to 25 of 70

 
All times are GMT -4. The time now is 09:03 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy