Visit The New, Modern Unix Linux Community

Search Results

Search: Posts Made By: Bab00shka
17,545
Posted By Bab00shka
'Awk' will be the quick way to do this....
'Awk' will be the quick way to do this. Unfortunately I'm not an expert in the syntax, but from experience its much faster that a standard shell script.

Cheers
Helen
11,509
Posted By Bab00shka
Hi Swapneel At the chosen time. run a script...
Hi Swapneel

At the chosen time. run a script which contains the if condition. it will have the desired effect and will also make the crontab file easier to read.

Cheers
Helen
14,637
Posted By Bab00shka
or, dependant on your system ux2dos dos2ux
or, dependant on your system

ux2dos
dos2ux
Forum: Cybersecurity 03-01-2006
4,359
Posted By Bab00shka
SSH - prevent roaming around the server
Hi,

We have a user who needs to connect to us over the internet using an ssh client. We use HP-UX 11.00.

We set up a home directory with login and password for them. We would not want to give...
2,468
Posted By Bab00shka
Try doing an ls -l of the file path before each rm
Try doing an ls -l of the file path before each rm
1,606
Posted By Bab00shka
What errors are you getting?
What errors are you getting?
2,441
Posted By Bab00shka
Try using -prune Your question has been...
Try using -prune

Your question has been answered here (https://www.unix.com/showthread.php?t=17854&highlight=prune)
2,441
Posted By Bab00shka
Use 'find' from the find man page: ...
Use 'find'

from the find man page:

Numeric arguments can be specified as

+n for greater than n,

-n for less than n,

n for exactly n.


so find . -mtime +1
finds all files older...
3,060
Posted By Bab00shka
Try: a=`cat date_file` This will...
Try:

a=`cat date_file`

This will assign the file contents to a
6,229
Posted By Bab00shka
to get the file size file_size=`ls -l...
to get the file size

file_size=`ls -l <path_to_file>| awk '{ print $5 }'`

then do an if

if [ $file_size -lt <size> ]
then
exit
fi
2,536
Posted By Bab00shka
Can you explain in a little more detail please? ...
Can you explain in a little more detail please?

Do you mean move the contents of each directory into one directory?
What do you want to compare in each directory?

Cheers
Helen
2,098
Posted By Bab00shka
Thanks Vergersh99, That worked fine :) ...
Thanks Vergersh99,

That worked fine :)
Cheers
Helen
2,098
Posted By Bab00shka
Just noticed that this deletes the whole line, I...
Just noticed that this deletes the whole line, I would like it to just delete the word. Its quite possible the file may look like this:

. ..
.Xauthority ...
2,098
Posted By Bab00shka
Sed help please
Hi,

I have a file which may look like this

. ..
.Xauthority .cshrc ...
52,979
Posted By Bab00shka
Hi ZB, This works fine, many thanks again...
Hi ZB,

This works fine, many thanks again Zazzy!

Cheers
Helen ;)
162,542
Posted By Bab00shka
Thanks Zazzy you're a star. I'll give this a...
Thanks Zazzy you're a star.

I'll give this a try.

Cheers
Helen :-)
162,542
Posted By Bab00shka
SFTP batch script
Hi,

I am running an sftp batch script.

sftp -b user@host <<EOF >> /tmp/file.out
binary
put file.txt
bye
EOF

However, I am getting errors.

No such file or directory...
52,979
Posted By Bab00shka
Hi MizzGail I can list the files in...
Hi MizzGail

I can list the files in interactive mode. in batch mode I need to bring the list back to a file, in a similar way to how 'nlist' works in ftp.

Rgds
Helen
7,156
Posted By Bab00shka
Hi Blowtorch Have a look at this link...
Hi Blowtorch

Have a look at this link (http://www.pragmasys.com/Fortress/WebHelp/html/sftp.htm)

Its the status messages at the end of the page. How do I retrieve them when using batch mode...
7,156
Posted By Bab00shka
Thanks for your help vgersh99. We are using...
Thanks for your help vgersh99.

We are using the standard HP-UX version of sftp.

I'm not quite sure how to capture the return codes in batch mode - any ideas?

Cheers
Helen
5,517
Posted By Bab00shka
Hi Gord, Is it possible that your password...
Hi Gord,

Is it possible that your password contains any Unix control characters? I've had problems before with password that contan chrs such as #$^*! etc.

Cheers
Helen
7,156
Posted By Bab00shka
Return codes
Hi,

Can anyone tell me if there are return codes for SFTP? If so how would you capture them? I've tried 'man sftp' but its not particularly helpful.

Many thanks
Helen :confused:
52,979
Posted By Bab00shka
SFTP help please
Hi,

I have been using the ftp command "nlist . localfile.txt" in my batch scripts to bring back a listing of the remote directory and add it to localfile.txt

I now need to do an sftp batch...
1,614
Posted By Bab00shka
Hi Ygor, That works great - thank-you :) ...
Hi Ygor,

That works great - thank-you :)

Helen
1,614
Posted By Bab00shka
Quick question on file position
Hi,

Is there a simple way, using ksh, to find the byte position in a file that a stated character appears?

Many thanks
Helen
Showing results 1 to 25 of 123

 

Featured Tech Videos

All times are GMT -4. The time now is 06:07 AM.
Unix & Linux Forums Content Copyright 1993-2020. All Rights Reserved.
Privacy Policy