- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: cron job not finding files
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-14-2002 01:16 AM
05-14-2002 01:16 AM
I wonder if someone can suggest a theory to small but annoying problem I am having....
I have a cron job that creates a number of files and then at the end attempts to move some of the files that have been created but gives the following (output from elm with debug on):
mv /opt/unikix/rurdev/usertran.${yymmdd}*.* /shared/stats
+ mv /opt/unikix/rurdev/usertran.020513*.* /shared/stats
mv: /opt/unikix/rurdev/usertran.020513*.*: cannot access: No such file or direct
ory
but I can do an ll of them quite happily (as the same user):
$ ll /opt/unikix/rurdev/usertran.020513*.*
-rw-r--r-- 1 batch unikix 136180 May 14 07:37 /opt/unikix/rurdev/use
rtran.020513.05.13.08.10
-rw-r--r-- 1 batch unikix 284596 May 14 07:37 /opt/unikix/rurdev/use
rtran.020513.05.13.10.120
-rw-r--r-- 1 batch unikix 137389 May 14 07:38 /opt/unikix/rurdev/use
rtran.020513.05.13.12.140
-rw-r--r-- 1 batch unikix 258479 May 14 07:38 /opt/unikix/rurdev/use
rtran.020513.05.13.14.160
-rw-r--r-- 1 batch unikix 189326 May 14 07:39 /opt/unikix/rurdev/use
rtran.020513.05.13.16.180
-rw-r--r-- 1 batch unikix 189326 May 14 07:39 /opt/unikix/rurdev/use
rtran.020513.05.13.18.195
and can then move them manually.
I have checked the time stamps and they do exist at this point, permissions look OK.......
so can anyone suggest what the problem might be??
Any help greatly appreciated
Cheers
Ian
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-14-2002 01:23 AM
05-14-2002 01:23 AM
Re: cron job not finding files
Nothing obvious
Have you tried
mv /opt/unikix/rurdev/usertran.020513*
as opposed to
mv /opt/unikix/rurdev/usertran.020513*.*
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-14-2002 01:24 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-14-2002 01:40 AM
05-14-2002 01:40 AM
Re: cron job not finding files
Just a thought - could it be that the script contains hidden characters in the line
mv /opt/unikix/rurdev/usertran.${yymmdd}*.* /shared/stats
which would prevent the files being found?
John
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-14-2002 02:55 AM
05-14-2002 02:55 AM
Re: cron job not finding files
But the cron daemon will not source your .profile before invoking the job, so you'll have to explicitly do a "set +f" or source your .profile in your cron job command.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-14-2002 04:09 AM
05-14-2002 04:09 AM
Re: cron job not finding files
Works as user !!!
Not in Cron !!!
Then has to be environmental variable.
Check the users .profile, there is somthing missed.
As already said set +f looks to be the reason.
Paula