- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- How to do an ls and show the path
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
04-29-2008 06:25 AM
04-29-2008 06:25 AM
I would like to list all the directories and files of one dir.
Is there any instruccion to make it?
For exemple:
/tmp
/tmp/dir1
/tmp/dir1/file1
/tmp/dir2
/tmp/dir2/file1
/tmp/dir3
/tmp/file1
/tmp/file4
Thanks a lot of,
Carmen.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 06:29 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 06:30 AM
04-29-2008 06:30 AM
Re: How to do an ls and show the path
Of course, if you want to include more of the attributes, do:
# find /tmp -exec ls -ld {} \+
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 09:57 AM
04-29-2008 09:57 AM
Re: How to do an ls and show the path
You can break it down even more say by size with:
find /opt -mount -mtime -1 -type f -ls -ld| awk '{ print $7 " " $11 }' | sort -n | tail -20
Many variables to manage and change though dependant on what you need.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 10:05 AM
04-29-2008 10:05 AM
Re: How to do an ls and show the path
find /tmp -type f -size +1000000c -exec ls -ld {} \; | sort -rn | more
Or you can switch sizes or names or whatever you want basically.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 10:10 AM
04-29-2008 10:10 AM
Re: How to do an ls and show the path
find /tmp -type f â xdev -size +1000000c -exec ls -ld {} \; | sort -rn | more
Ok I will leave you all alone now. Good Luck.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 10:10 AM
04-29-2008 10:10 AM
Re: How to do an ls and show the path
dear carme
see find command
man find
thanks and regards
sajjad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 11:23 AM
04-29-2008 11:23 AM
Re: How to do an ls and show the path
ls -R -1 /tmp
The ls man page is quite large with all the extra options.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 11:40 AM
04-29-2008 11:40 AM
Re: How to do an ls and show the path
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 11:40 AM
04-29-2008 11:40 AM
Re: How to do an ls and show the path
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-29-2008 05:28 PM
04-29-2008 05:28 PM