10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have multiple files test1, test2, test3 etc. I want to move to a different directory with ABC_ prefixed to every file and and current dat time as postfix using a single command. (I will be using this is sftp with ! (command for local server).
I have tried the following but it gives error
... (5 Replies)
Discussion started by: Soham
5 Replies
2. Shell Programming and Scripting
Hi :),
I am new to Unix and Shell Script
I have a urgent requirement, where i am new to shell script and Unix
my requirement is I have a files in a folder like
sales-prod-India-details.txt
sales-prod-japan-details.txt
sales-prod-china-details.txt
My SFTP server has ... (3 Replies)
Discussion started by: spradeep86
3 Replies
3. Shell Programming and Scripting
Hi,
In sftp script to get files, I have to rename all the files which I am picking. Rename command does not work here. Is there any way to do this?
I am using #!/bin/ksh
For eg: sftp user@host <<EOF
cd /path
get *.txt
rename *.txt *.txt.done
... (7 Replies)
Discussion started by: jhilmil
7 Replies
4. Shell Programming and Scripting
Hi,
i need a single command to create multiple empty files(no trailing lines as well) and empty the files if already existing.
please let me know or if this has been ansered, if some ocan share the link please, thanks
> newfile.txt
or
:> newfile.txt
do not work (4 Replies)
Discussion started by: Onkar Banerjee
4 Replies
5. Shell Programming and Scripting
I have a log directory:
/logs/foo.log
/logs/bar.log
/logs/err.out
I'm trying to find a way to
> /logs/*.log
> /logs/*.out
to blank them out, but of course, that doesn't work.
Any suggestions? (4 Replies)
Discussion started by: Validatorian
4 Replies
6. Shell Programming and Scripting
Hi Experts,
Please help me to write the expect script for uploading multiple files in one shot . Below is my program that I have written.
#!/usr/local/bin/expect -f #/home/kulbhushan/sftp_prog.sh
# procedure to attempt connecting; result 0 if OK, 1 otherwise
proc connect {passw} {
expect... (1 Reply)
Discussion started by: kulbhushan
1 Replies
7. UNIX for Dummies Questions & Answers
Hi,
I will use below command for grep single string ("osuser" is search string)
ex: find . -type f | xarg grep -il osuser
but i have one more string "v$session"
here i want to grep in which file these two strings are present.
any help is appreciated,
Thanks in advance.
Gagan (2 Replies)
Discussion started by: gagan4599
2 Replies
8. UNIX for Dummies Questions & Answers
Dear Unix Guru,
I have several directories as below
/home/user/
dir1
dir2
dir3
Each directory has different size. I want to print each directory size (Solaris command du -hs .)
Can you please guide me how to achieve this?
Thanks
Bala (2 Replies)
Discussion started by: baluchen
2 Replies
9. Shell Programming and Scripting
Hi
I have following list of files at a path:
01.AR.asset
01.AR.index
01.AR.asset.vf
01.AR.asset.xv
I want to rename all these files as follows:
73.AR.asset.Z
73.AR.index.Z
73.AR.asset.vf.Z
73.AR.asset.xv.Z
Can any body give me a single command to acheive the above results.
... (5 Replies)
Discussion started by: tayyabq8
5 Replies
10. UNIX for Dummies Questions & Answers
Hi,
I'm new to using the sftp command prompt within the unix shell (usually I just use an FTP windows program).
I've successfully connected to a remote server from within ssh. I've also been able to copy multiple files using the mget command
e.g. mget *.html
How do I copy all files,... (3 Replies)
Discussion started by: robbieg
3 Replies