General :: DU Style Directory Listing With File Numbers

Sep 6, 2010

Is there a command to return a recursive listing of sub-directories and the number of files in them? I have found plenty of ways to give me the total number of files in a directory structure, but none that gives a list of the sub-directories with the number of files in them. "du" gives me a listing of directories with their sizes, but I couldn't find an option (or any other way) to give me the number of files as well. Ideally, I'd like to get list with "Size" "Files" "Dir name" - And the order of the columns doesn't matter. Is there a "simple" command line solution or do I need a shell script for that?

View 5 Replies


ADVERTISEMENT

General :: Listing Directory And Files' Permission Into Numbers?

Jul 20, 2010

Is it possible for listing directory and files' permission into numbers?

Generally ls command shows directory and files' permission as follows;

[root:maestro:/home/ddisk_net]# ls -al
Total 44
drwx------ 4 ddisk_net users 4096 7월 20 10:40 .
drwxr-xr-x 21 root root 4096 7월 20 10:28 ..
-rw------- 1 ddisk_net webteam 5 7월 20 10:40 .bash_history
-rw-r--r-- 1 ddisk_net users 33 1월 22 2009 .bash_logout

[code].....

View 9 Replies View Related

General :: Prevent A User From Seeing A File In A Directory Listing?

May 3, 2011

I have, for example, a folder called "MyFolder" and it contains 3 files: MyFile1, MyFile2, MyFile3. The only file that I do NOT want a particular user/group to even see that it exists is, for exmple, MyFile2.So, when they do a directory listing on MyFolder, they should only see MyFile1 and MyFile3. How can this be done in Linux? The important thing is that it is not just preventing them from "executing" MyFile2, but to prevent them from even knowing that it exists by not including it in a directory listing.This is a simpified example using one file, but in reality, I have lots of files and some of those that I want to block are also subfolders.It is very important for me to hide the existence of certain files/folders when the user does a directory listing. It's also important that the files stay in their current folder (that is, I can't use a workaround which requires moving all the files into a separate folder and then securing that folder).

View 4 Replies View Related

General :: Perform A Long Directory Listing Of All Files In The /bin Directory That Have Exactly Three Characters In Their Name?

Jan 18, 2010

How do you perform a long directory listing of all files in the /bin directory that have exactly three characters in their name?

View 1 Replies View Related

Ubuntu :: Firefox Opens File Listing Instead Of Nautilus Opening File Listing

Jun 20, 2010

Firefox opens file listing instead of Nautilus opening file listing.When I access a folder via "Places" -> "Home Folder" or "Places" -> "Downloads", Firefox opens and list the contents of the directory.I have re-installed Nautilus, un-installed Firefox and then going to "Places" -> "Home Folder" or "Places" -> "Downloads" launches Nautilus and I can view the contents normally. Anybody else had this problem with Firefox ? Anybody know how to fix this Firefox problem ?Running Ubuntu Desktop 9.10 64bit.

View 2 Replies View Related

Ubuntu Servers :: Directory Listing Missing File Icons For Apache

Sep 9, 2010

For some reason my directory listings are missing their icons for Apache on Ubuntu Server. An example: [URL]. They all come up not found.

View 6 Replies View Related

General :: Directory Listing On A Usb Drive?

Jan 24, 2011

I have a usb drive which I will call it "mydrive" for this discussion. I am trying to get to it so I can do a ls -al on the usb device itself.

But I'm not sure how to get to the dir entry for the device.

View 4 Replies View Related

General :: Listing TAR Contents Inside Directory

Jun 16, 2011

This is the script I'm running
tar tf some.tar somefolder_insidetar
And output it's a list with all folders, files, and SUBDIRECTORY Files, the only thing I need it's just show the contents (folder and files) of the current directory choosed, not listing subdirectory files, or subdirectories inside subdirectories.

View 3 Replies View Related

General :: Vsftp Doesn't Do Initial Directory Listing?

Aug 4, 2010

I have a user who just got a new laptop and when he connects to the FTP server, it verifies his username and password like it should, but when it goes to do the directory listing, it just kinda sits there. if i refresh the view, the folders show up. wonder if there's something in a log somewhere for vsftp i should be looking at. it could just be his ftp client or air card too, but i want to be thorough on the server too becuase it will help me learn.

View 2 Replies View Related

General :: Find Files In A Directory That Contain Numbers?

Mar 1, 2011

I am trying find files in a directory that contain numbers. I have tried ls /etc *[0-9]* but that doesn't work. If I cd to /etc and run ls *[0-9]* it almost works but it also includes results from within files. My last thought was to try: find /etc [0-9] -type f but this does not work either. My second problem is that I am trying to get list of files in a directory that were changed less than 10 hours ago, using grep, while leaving out directories. I am completely stuck with the second problem.

View 8 Replies View Related

General :: Write A Script To Convert All DOS Style Backslashes To UNIX Style Slashes?

May 20, 2011

How do I write a script to convert all DOS style backslashes to UNIX style slashes in a list of files /

View 3 Replies View Related

Red Hat :: RHEL5 Apache Directory Listing For A Directory?

Feb 1, 2010

I have RHEL5 with apache installed and running. I have a directory off of / called software that I would like to have show up as a directory listing so if I go to [URL] I get the directory listing. I have tried searching around and nothing seems to work for me. So out of the box how do I get this to work? My server properly resolves to [URL] so I am good there.

View 8 Replies View Related

General :: Listing Of Zip File Contents Using C?

Oct 20, 2009

how to do the listing of zip file contents using C?

View 1 Replies View Related

General :: Replace Sequential Numbers In A File With A Different Sequence Using Sed?

Apr 11, 2010

I am trying to find a way to replace a set of sequential numbers in a file with a different sequence using sed. This might be done easier using awk or some sort of bash script, but it seems to me there must be a way to do this easily with sed. Basically, what I am editing is a Cisco switch config. I want to change the sequence of ports to a different numbered sequence. Here is an example of what I am trying to do.I want to change for example, the file:

Code:
cat testfile
interface FastEthernet0/1

[code]...

View 6 Replies View Related

Ubuntu Servers :: Allow Windows-style Directory Separators?

Mar 25, 2010

I'm porting an application to a Ubuntu server which contains hard coded windows-style file separators (e.g. "\examplefile.conf"). Of course, this doesn't work on Linux. Is there any way I can allow it? I'm trying to avoid rebuilding the source code.

View 3 Replies View Related

Fedora :: Mv() Command - Tedious Directory Listing?

Oct 22, 2010

Within the mv() command is there any way to not need to type the entire directory location? In the example there are directories with varying depths... I want to move a file from depth 2 to a directory of depth 3 when the directory of depth 3 is within the directory of depth 2. Basically, can I cp() andor mv() a file to a subdirectory without having the enter the entire directory location?

Code:

[root@xxx dir]# ls
dirD1
[root@xxx dir]# cd dirD1/dirD2
[root@xxx dirD2]# ls

[code]....

View 6 Replies View Related

Ubuntu :: 9.1 With Samba - Deny Directory Listing

Mar 19, 2010

I have set up Ubuntu 9.1 with Samba etc. as a web server. The files are in /var/www and are shared through Samba as web. The root directory and sub directories have index.htm files in them but unfortunately except for the root directory users can see the directory listing rather than the directory automatically producing index.htm. This is obviously causing security problems. How to prevent directory browsing by users coming into the server over the internet by a redirect URL from another site. E.g. [URL] where bigwebsite is a domain registered with a change ip server because I have a service which dynamically allocates an IP Address.

View 3 Replies View Related

Software :: Directory Listing Of Files That Don't Exist?

Oct 16, 2010

I think as a result of a script that started duplicating files in a loop, the allotted capacity on my VPS filled up with multiple nested copies of the same files... After a reboot, I could delete most of them, but got rm stalled in certain directories...

after isolating which ones, I found this: a directory listing that lists the files, and at the same time tells me they are not there!!!

partial listing:

Code:
ls
ls: cannot access userkey.php: No such file or directory
ls: cannot access workshop.php: No such file or directory
ls: cannot access quiz.php: No such file or directory
ls: cannot access webservice_rest.php: No such file or directory

[Code]....

View 5 Replies View Related

General :: Reading Numbers From Text File And Storing In Array?

May 26, 2010

I'm writing a bash script where I read a text file (containing a column of numbers) and store each line in an array. There seem to be some problems with the whole thing however, but only for some files and not others. Here's what I do:

Code:
#!/bin/bash
file=time_notOk.txt ### The file with a column of numbers
i=0 ### Array counter
### Read the file

[Code]....

View 3 Replies View Related

Ubuntu :: Get A Recursive Listing Of All Files Under The Current Directory?

Jan 2, 2011

If I runls -R1I get a recursive listing of all files under the current directory.However, if I dols -R1 *.avi, ie I want to search only for files with the file descriptor .avi, I get an errorQuote:ls: cannot access *.avi:No such file or directorySo it seems I am using ls incorrectly. What's the correct way to use wild card pattern matching when using the -R switch? Or maybe that isn't possible?

View 2 Replies View Related

Programming :: Pipe The Current Directory Listing Into Sort?

Oct 20, 2010

how to pipe the current directory listing into sort so that the output is the date in descending order (primary sort key). If there are multiple entries with the same date, I'd like the times sorted in ascending order. It seems simple but for some reason this isn't working:

ls -l | sort -k 6r -k 7

For some reason it doesn't seem to ever get to the second sort key when using column 6 (last modified date).

View 2 Replies View Related

General :: Bash + Reading Values (numbers) From A File And Storing Them Into An Array?

Nov 4, 2010

I have to read a couple of numbers from a random.txt file. In this .txt file there are random numbers. They are separated by a space. Example if you opened test.txt:

test.txt :1 6 1 3 6 8 10 2 4

I would like to read those numbers using CAT and store them into an array:

numlen=${#num[*]} - (must be like this because it is a part of a larger program)

View 5 Replies View Related

Ubuntu Servers :: Simple Php Script - Directory Listing Output

Oct 6, 2010

Just want a very simple directory listing output, no real need for hyperlinks, preferably with a line space between items, that the end user can print out.

I have this code, just don't have the knowledge to make it do what I want.

Quote:

View 6 Replies View Related

OpenSUSE Network :: Blocking Filezilla / Getting 425 Error Cant Retrieve Directory Listing?

Apr 26, 2011

I obviously a noob to Suse but after installing 11.4, and filezilla, i cant connect to my ftp server. Ive opened ports 21 22 and 990 explicitly in the firewall and all I get is a 425 error Cant Retrieve Directory Listing. It logs me in ok but doesnt allow data connections?

View 9 Replies View Related

Ubuntu Servers :: Make Apache Show Symbolic Links In A Directory Listing?

Jul 17, 2011

I am trying to make my Apache server show symbolic links in a directory listing, but have so far been unsuccessful. In my latest attempt, I have placed the following code in .htaccess, in the directory with the symlinks that I want listing:

Code:
<Directory />
Options All
</Directory>
Im httpd-vhosts.conf, I have also placed the following code within the relative <VirtualHost></VirtualHost>:

View 5 Replies View Related

Debian Multimedia :: Notification In Bar Style Instead Of Box Style?

Nov 14, 2015

which kind of package enables the notification bar ("(A) Connection Established I'm running Code: Select allLinux 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1+deb8u5 (2015-10-09) x86_64 GNU/Linux on two machines with i3 window manager but one have notifications in a box, the other one in a bar on the top of the screen. I would like two enable the "bar style" on the second machine as well.

View 4 Replies View Related

Ubuntu :: PCMan File Manager File/folder Numbers In Wrong Order?

Jul 25, 2011

I have recently switched to using LXDE on my PC and I am on the whole pretty pleased with it. However,PCMan is giving me a really odd problem. Some of the files/folders are being displayed in the wrong order where they contain numbers. They are being ordered by their first digit not the whole number.

[Code]...

View 5 Replies View Related

Ubuntu :: Bibtex Style File Missing

May 3, 2011

I'm trying to use a bibtex style file from the texlive-publishing package, but bibtex cant seem to find the .bib file even though I've tried everything from placing it in the same directory to exporting the BST to: p, li { white-space: pre-wrap; } export BSTINPUTS=/usr/share/texmf-texlive/bibtex/bib/IEEEtran/ but bibtex still cant find my file.

View 1 Replies View Related

Fedora Networking :: Dropbox Style VPN File Sharing?

May 11, 2009

Is there a way to share files over a VPN with a Dropbox type download system? I want the files to be able to update to a local file on the clients when updated on the server.

View 5 Replies View Related

Ubuntu :: Bibtex Style File Missing From Package

May 3, 2011

I'm trying to use a bibtex style file from the texlive-publishing package, but bibtex cant seem to find the .bib file even though I've tried everything from placing it in the same directory to exporting the BST to:
export BSTINPUTS=/usr/share/texmf-texlive/bibtex/bib/IEEEtran/
But bibtex still cant find my file.

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved