HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Pax command help
Operating System - HP-UX
1833776
Members
1956
Online
110063
Solutions
Forums
Categories
Company
Local Language
back
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
back
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
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- 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
01-02-2004 06:45 AM
01-02-2004 06:45 AM
I am trying to extract a tar file using pax command and I need to retain the timestamp on the files.
pax -pe -rv <$t_tar_file
The tar file is generated on a Unix host which is situated in west coast of US. When I extracted the tar file on a Unix host which is situated in Europe (a time zone difference of 9hrs) the creation time of the file is changed to creation time at source + 9hrs (time zone difference).
Example file in source
------------------------
drwxrwsr-x 2 apps dev 96 Aug 14 17:10 rk3124
Example file in target
------------------------
drwxrwxr-x 2 apps dev 96 Aug 15 02:10 rk3124
Could some body help how to avoid the change in time stamp on the file in target machine. Thanks in adv.
pax -pe -rv <$t_tar_file
The tar file is generated on a Unix host which is situated in west coast of US. When I extracted the tar file on a Unix host which is situated in Europe (a time zone difference of 9hrs) the creation time of the file is changed to creation time at source + 9hrs (time zone difference).
Example file in source
------------------------
drwxrwsr-x 2 apps dev 96 Aug 14 17:10 rk3124
Example file in target
------------------------
drwxrwxr-x 2 apps dev 96 Aug 15 02:10 rk3124
Could some body help how to avoid the change in time stamp on the file in target machine. Thanks in adv.
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2004 07:31 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2004 07:43 AM
01-02-2004 07:43 AM
Re: Pax command help
To see the time stamp as it is for US Pacific time zone, you would have to set the time zone for your session.
# export TZ=PST8CDT
Then do an 'll' and you should see the time stamps match.
# export TZ=PST8CDT
Then do an 'll' and you should see the time stamps match.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-02-2004 01:42 PM
01-02-2004 01:42 PM
Re: Pax command help
HP-UX only keeps one time: GMT (aka, Zulu or UTC) and tar saves the timestamps in that time. When you list or restore the files, the timestamp is interpreted based on the current setting for TZ. So no matter where you restore the files, the timestamp is correct based on the location where they were saved. This is why users all over the world can login to an HP-UX system and with their TZ set to the local timezone, all date stamps will be correct for the local timezone.
Bill Hassell, sysadmin
Bill Hassell, sysadmin
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP