• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Unix Shell Script to archive file with time bound - random access file

 
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

I need shell script or UNIX command to archive a file in UNIX OS. this file should be archived on a weekly basis.
and also this file is randomly accessed by different applications.

Can you please provide solution for this.

Thanks in Advance!!

-Ravi
 
Saloon Keeper
Posts: 27762
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There are several Unix archive utilities. Most common is tar, but there's also a Linux ZIP, and cpio.

I do nightly backups using tar. The actual scheduling is done by the cron utility.

The vixie cron popular on Linux is set up with a set of script folders, including /etc/cron.daily and /etc/cron.weekly, where you can place executable scripts and they will run automatically. If you prefer a different scheduling arrangement, you can add entries to the /etc/crontab file.

Also, for non-system usage, each user account can have its own crontab. The format is slightly different from the system crontab.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic