08-25-2003
It looks to me like this actually is a date calculation question. He posted on Aug 21, 2003 and said that he wanted filename.n where n was 233. By that numbering scheme, Jan 1, 2003 would be 1 while Dec 31, 2003 would be 365. But next year is a leap year, so Dec 31, 2004 would be 366.
Calculations like that are easy if you use my datecalc script which is
right here. You can use the -j option to calculate julian day numbers. "datecalc -j 2002 12 31" will return 52639. And "datecalc -j 2003 8 21" will return 52872. And 52872 - 52639 = 233.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Some users get on our server with ftp with a specific username (i.e. guest). The users guest has an own group. The user guest is in the path /usr/guests after login.
How can I lock the user guest that he don't get up to the /usr treee. I tried to change the rights for the ..
But it's not anymore... (1 Reply)
Discussion started by: arn_ch
1 Replies
2. UNIX for Dummies Questions & Answers
How does one ftp an entire directory from one Solaris 5.9 machine to another with out moving one file at a time? (4 Replies)
Discussion started by: DarkLord
4 Replies
3. UNIX for Dummies Questions & Answers
Hi guyz,
Is there any way to ftp a whole directory structure.
I mean is there any way using which I can get the whole directory ftpied including the subdirectories
Thanks and regards,
Gauravv (17 Replies)
Discussion started by: gauravgoel
17 Replies
4. UNIX for Dummies Questions & Answers
Hi,
I have a requirement where I have get the files from FTP server then delete the files in the FTP server and then store the file name within the file where there is "TR".
i.e
Filename|TR|20071231|....
Once I finish loading my file I have to archive the files.
Is there any way to do it... (2 Replies)
Discussion started by: kiran_418
2 Replies
5. Solaris
hi all
how I can create an ftp user in solaris 10 and have read and write permission on a directory.
Thanks. (1 Reply)
Discussion started by: luisfja
1 Replies
6. Shell Programming and Scripting
Hi All,
I want to search for .log files from folders and sub folders in remote server and FTP them to one particular folder in the local machine. I dont want to copy the entire directory tree structure, just have to take all the .log files from all the folders by doing a recursive search from the... (3 Replies)
Discussion started by: dassv
3 Replies
7. AIX
Hi,
I want to set FTP server on AIX to read only mode. I found out manual page for /etc/ftpaccess.ctl (manual page ).
I tried put readonly: ALL or
readonly: ALL
writeonly: NONE
and nothing happened (of course, I restart FTP server by stopsrc -t ftp; startsrc -t ftp) (2 Replies)
Discussion started by: henriette
2 Replies
8. Shell Programming and Scripting
HI Guys,
I have downloaded the oracle binaries from oracle.com, i have unziped them in a directory say OWB. I have to copy them to my windows server so i have ran the ftp command.
It looks like i can ftp whole directory.
Can you please get me the command to get all the files and... (7 Replies)
Discussion started by: guddu_12
7 Replies
9. UNIX for Dummies Questions & Answers
hi,
i need ftp commands which read a text file and ftp the contents of the file to a another machine.
Anyone can help me out please. (2 Replies)
Discussion started by: kamaldev
2 Replies
10. Shell Programming and Scripting
I have system that generate files every 1 hours , i only have ftp connection from my local server to remote .
$ ls -al
-rw-r--r-- 1 water None 0 Feb 7 18:09 a.0800
-rw-r--r-- 1 water None 0 Feb 7 18:09 a.0900
-rw-r--r-- 1 water None 0 Feb 7 18:09 a.1000
is there any perl / php... (3 Replies)
Discussion started by: before4
3 Replies
LEARN ABOUT LINUX
run-parts
RUN-PARTS(8) System Manager's Manual RUN-PARTS(8)
NAME
run-parts - run scripts or programs in a directory
SYNOPSIS
run-parts [--test] [--verbose] [--report] [--lsbsysinit] [--regex=RE] [--umask=umask] [--arg=argument] [--exit-on-error] [--help] [--ver-
sion] [--list] [--reverse] [--] DIRECTORY
run-parts -V
DESCRIPTION
run-parts runs all the executable files named within constraints described below, found in directory directory. Other files and directo-
ries are silently ignored.
If neither the --lsbsysinit option nor the --regex option is given then the names must consist entirely of ASCII upper- and lower-case let-
ters, ASCII digits, ASCII underscores, and ASCII minus-hyphens.
If the --lsbsysinit option is given, then the names must not end in .dpkg-old or .dpkg-dist or .dpkg-new or .dpkg-tmp, and must belong to
one or more of the following namespaces: the LANANA-assigned namespace (^[a-z0-9]+$); the LSB hierarchical and reserved namespaces
(^_?([a-z0-9_.]+-)+[a-z0-9]+$); and the Debian cron script namespace (^[a-zA-Z0-9_-]+$).
If the --regex option is given, the names must match the custom extended regular expression specified as that option's argument.
Files are run in the lexical sort order of their names unless the --reverse option is given, in which case they are run in the opposite
order.
OPTIONS
--test print the names of the scripts which would be run, but don't actually run them.
--list print the names of the all matching files (not limited to executables), but don't actually run them. This option cannot be used with
--test.
-v, --verbose
print the name of each script to stderr before running.
--report
similar to --verbose, but only prints the name of scripts which produce output. The script's name is printed to whichever of stdout
or stderr the script first produces output on.
--reverse
reverse the scripts' execution order.
--exit-on-error
exit as soon as a script returns with a non-zero exit code.
--lsbsysinit
use LSB namespaces instead of classical behavior.
--new-session
run each script in a separate process session. If you use this option, killing run-parts will not kill the currently running
script, it will run until completion.
--regex=RE
validate filenames against custom extended regular expression RE. See the EXAMPLES section for an example.
-u, --umask=umask
sets the umask to umask before running the scripts. umask should be specified in octal. By default the umask is set to 022.
-a, --arg=argument
pass argument to the scripts. Use --arg once for each argument you want passed.
-- specifies that this is the end of the options. Any filename after -- will be not be interpreted as an option even if it starts with
a hyphen.
-h, --help
display usage information and exit.
-V, --version
display version and copyright and exit.
EXAMPLES
Print the names of all files in /etc that start with `p' and end with `d':
run-parts --list --regex '^p.*d$' /etc
COPYRIGHT
Copyright (C) 1994 Ian Jackson.
Copyright (C) 1996 Jeff Noxon.
Copyright (C) 1996, 1997, 1998 Guy Maor
Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Clint Adams
run-parts is free software; see the GNU General Public License version 2 or later for copying conditions. There is no warranty.
Debian 14 Nov 2010 RUN-PARTS(8)