10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I am using HP-UXsystem. I am unable to use the below sed commands. could you please let us know the alternate commands for it.
>sed '/unix/ c "Change line"' file.txt
sed '/unix/ i "Add a new line"' file.txt
any inputs please (5 Replies)
Discussion started by: ramkumar15
5 Replies
2. Shell Programming and Scripting
if ]
then
rm -rf
Can anyone tell me what are they checking in the if loop
Please use code tags next time for your code and data. Thanks (2 Replies)
Discussion started by: ramkumar15
2 Replies
3. UNIX for Dummies Questions & Answers
hey guys, i'm in a unix course.. and while this is a homework question - i did put alittle effort into it. just wanted to ask before trial and error drives me nuts.
question 13 has us saving the last 30 characters of a file into another file
and question 14 has us saving the list of all the... (1 Reply)
Discussion started by: labelthief
1 Replies
4. UNIX for Dummies Questions & Answers
Hi I'm pretty new to scripting and I've been googling around looking for an answer but have yet to come up with a proper solution. I work with multiple android devices at a time and I'm looking to simplify my life with a script. Basically I'm looking for a script that takes the device ID's and then... (2 Replies)
Discussion started by: Onyoursix
2 Replies
5. Shell Programming and Scripting
Hello,
I have the following is a txt file:
!!! man.uni.com address 141.000.001 to you.uni.com
!!! man.uni.com address 141.000.002 to wae1.uni.com
!!! man.uni.com address 141.000.003 to kim2.uni.com
I want to get you,wae and kim from the text and put them in a diffrent file in the following... (2 Replies)
Discussion started by: andrew1400
2 Replies
6. Shell Programming and Scripting
what does this mean?
cat /etc/passwd | awk -F: '{print $5}' | \
awk -F, '{print $1}' | \
awk '{print tolower($l)};{print tolower($2)}' | \
grep -v '^$' >> local_tmp (1 Reply)
Discussion started by: hin-linux
1 Replies
7. Shell Programming and Scripting
I want to log into a remote server transfer over a new config and then backup the existing config, replace with the new config.
I am not sure if I can do this with BASH scripting.
I have set up password less login by adding my public key to authorized_keys file, it works.
I am a little... (1 Reply)
Discussion started by: bash_in_my_head
1 Replies
8. Shell Programming and Scripting
Is there a way to shorten these commands? because this script asks for a password 3 times
scp -p /usr/local/bin/${script_name} ${servername$iy]}://usr/local/bin/
ssh ${servernames} /usr/local/bin/${script_name}
ssh ${servernames} rm -f /usr/local/bin/${script_name}
Basically, I'm creating a... (3 Replies)
Discussion started by: pdtak
3 Replies
9. Programming
Hello all,
i've written a small piece of code that will read commands from standard input and executes the commands.
Its working fine and is execting the commands well. Accepting arguments too. e.g
#mkdir <name of the directory>
The problem is that its not letting me change the directory i.e... (4 Replies)
Discussion started by: Phrozen Smoke
4 Replies
10. UNIX for Advanced & Expert Users
I want to write a batch file that issues the rlogin command with the username and password. Is there a way to pass a user password to the rlogin command?
Thanks. (5 Replies)
Discussion started by: eyoakum
5 Replies