A file system structure in which to store computer files.

learn more… | top users | synonyms

0
votes
0answers
15 views

What are differences between directory order and alphebetic order with `ls`? [duplicate]

What are differences between directory order (-U) and alphabetic order (by default) with ls? They return the same order of a dir's contents to me.
-6
votes
2answers
46 views

How to you create directories and set permission? [on hold]

How do you create three directories in /storage named campaigns, financials, and public. Also, I'm wondering how to set the file access permissions as follows: campaigns – marketing group has full ...
0
votes
1answer
36 views

“Links” to dirs that have features of both hard and soft links?

It is not allowed to create a hard link for a dir. But the soft like will not work, if I later change the name of the dir. How would you solve the dilemma? Are there applications which can ...
5
votes
4answers
211 views

Ways to organize and access frequently visited directories and files?

In my Ubuntu, I have added some frequented directories to the bookmarks of Nautilus, for visiting them quicker. Nautilus can consume a lot of memory, when it has been kept open for long and there ...
2
votes
3answers
45 views

copying parallel directories Why does cp -r work this way?

The following works correctly (ie does what I want) cd /var/www/release/ mkdir wiki cp -rp ../html/wiki ./ However if I do (what seems more intuitive) cp -r ../html/wiki ./wiki it will ...
3
votes
2answers
106 views

Valgrind /usr/lib files are not regular Linux files

The problem that I encountered today (on an embedded device with Linux) is that some files (specifically, the Valgrind /usr/lib files) are behaving very strange and they are not copy-able with scp ...
0
votes
0answers
8 views

In Ubuntu, what is the folder in which MySQL's UDF should be installed?

I am using Ubuntu 14.04. I wonder where should I install binary UDF for MySQL. Is there any way to discover the path of the UDF directory? Is there a standard for this in Ubuntu?
4
votes
5answers
302 views

Bash pattern to match all files but directories

In bash, how do I specify a pattern that matches everything but subdirectories in current directory. Given that the pattern */ matches all the subdirectories, I tried (with extglob turned on): $ echo ...
0
votes
3answers
34 views

cd to the most recently created directory [duplicate]

I have a directory in which a number of directories are created daily. I want to enter into the directory which is created recently whose name starts with cy. How can I find this directory? Could ...
1
vote
3answers
144 views

Removing a directory that has no files in it

I recently created a username and a group called gamesForAdmin. Since then I deleted it and the folder I made for it is still there: drwxr-xr-x 5 root root 4096 Jul 4 11:28 . drwxr-xr-x ...
0
votes
1answer
16 views

remove special character from files in directory

I need to remove special characters from all .htm files in a directory. Ideally I need to keep the file name but if I have to I can copy each file to 1 or something like that. Here is the command I ...
2
votes
1answer
44 views

Create directory using filenames and move the files to its repective folder

I have a folder with around 150 text files. I would like to create folders in the name of the 150 files. After that I would like the text file to be moved to its respective folder. Example names of ...
1
vote
2answers
46 views

Do Links to /tmp files get deleted?

I have a script that creates a temp directory using mktemp -d. A folder generated in the temp directory is the output of the script that will be copied to another part of the machine. I was ...
9
votes
4answers
322 views

Recursively iterate through files in a directory

Recursively iterating through files in a directory can easily be done by: find . -type f -exec bar {} \; However, the above does not work for more complex things, where a lot of conditional ...
1
vote
1answer
77 views

Trouble installing lxml with custom install location for libxml2/libxslt

I am attempting to install a python module called lxml to my account on a supercomputer running RHEL. I do NOT have root access or super user status. lxml requires the dev/devel versions of libxml2 ...
3
votes
2answers
102 views

Find files in directory with paired names

I'm running tests of a variable-size-and-contents test set. Data files are added and removed frequently. I'm looking for an automated way of gathering a file list. All files are in subdirectories of ...
1
vote
1answer
45 views

Only write permission for a directory doesn't allow to rename (move) files inside?

In fact, I would like to ask more general question -- "what does write permission for a directory allow you to do exactly?" -- but let's approach it with a concrete example. It is a long question, if ...
1
vote
2answers
49 views

tar compression without directory structure

Under my current directory, I have two sub-directories: dir_1/ - file1.png - file2.png ... - fileN.png dir_2/ - fileA.txt - ... - fileZ.txt When I tar compress the two ...
0
votes
1answer
23 views

Moved folder into other has now disappeared

Two folders in same directory and I wanted to move one into other with command mv foo /foo2 but now foo has vanished.
9
votes
3answers
338 views

How to spoof/mock a directory used by a binary application as another directory?

Suppose there's a binary application that always writes its data to /tmp. How could I spoof/mock /tmp for the sake of this binary as some other directory (e.g. home/tmp)? Let's assume I have no ...
3
votes
3answers
175 views

Return to directory location prior to cd-ing to home directory

As is well known, cd without an argument changes one's current directory to their home directory. I am wondering if there is any way, after using the cd command like this, to return to the directory ...
2
votes
2answers
87 views

inotifywait different action on file or dir

I'm trying to make a inotifywait script take different actions for files vs folders if it sees a close_write flag being raised in the watched directory, but cannot seem to get the checks working. In ...
4
votes
4answers
754 views

Can the /home folder in Linux contain anything else but user folders?

Can the /home folder contain anything else but user folders? I have a folder I want to share between Windows and Arch - can it go in the home folder under a name not belonging to any existing user? ...
2
votes
3answers
89 views

What is the difference between path and directory?

I don't understand the difference between path and directory. Could someone explain to me with examples?
2
votes
0answers
36 views

One way diff between 2 directories

I am looking to perform a diff between 2 directories, both of which contain may files and subdirectories. I am hoping to perform a one-way diff between a source and target directory that will return ...
1
vote
1answer
46 views

lost directory cannot find it with testdisk

I was moving a directory on my parents computer using a teamviewer session. The session responds slow and somehow, when I was moving the directory (location: /sdb/synchronisatie/nel/) something went ...
4
votes
2answers
62 views

setting default permissions with setfacl

I am trying to set default permissions on my directory structure using acl. I would like to have following default permissions for directories and for files respectively: drwx--x--- -rw-r----- but ...
1
vote
1answer
60 views

untar specific directory

tar tvf filename.tar gives me: -rwxrwxrwx 0/0 544795 2010-03-15 12:49 35 WOO WORDPRESS THEMES/bloggingstream.zip -rwxrwxrwx 0/0 1659095 2010-03-15 12:51 35 WOO WORDPRESS ...
4
votes
2answers
221 views

Determine what device a directory is located on

If I do # cd / # ln -s /home test # cd test # mount --bind $PWD /mnt the entry in /proc/mounts is /dev/sda2 /mnt ext4 rw,noatime,data=ordered 0 0 which is the device that is mounted to /home and ...
1
vote
1answer
61 views

On why touch, mv, etc., won't create subdirectories “as needed”

There are many Unix commands that will fail unless some subdirectory already exists, even though it would be a trivial matter for such commands to go ahead and create the missing subdirectory before ...
3
votes
2answers
168 views

Command for creating a directory and navigating into it directly? [duplicate]

Quite often I need to perform this two commands: mkdir abc cd abc I am curious whether there is a simple command (or an alias that I can create and use) to do it in one go, like user@GROUP:~$ mdcd ...
1
vote
2answers
38 views

`ls` fails for directory copied from Win and OSX [closed]

I'm not able to ls on a folder that I have just transferred from win7 to OSX via a FAT32 drive. I don't know how to search for an answer for this issue. I've attempted the following: sudo chmod ...
4
votes
3answers
384 views

Merging folders with mv?

If I move a folder with mv called "folder" to a directory that already contains "folder" will they merge or will it be replaced?
2
votes
1answer
172 views

Delete files/ folders with .nfs files

A lot of time when I delete a folder, it says cannot be deleted because of .nfs files Error - Device or resource busy How can I delete a folder ignoring these errors ( is there any flag in rm ...
0
votes
1answer
38 views

Dropbox on both Windows and Ubuntu 12.04.3 LTS

I have Dropbox installed on both Windows 7 and Ubuntu 12.04.3 LTS and there are two separate folders that are being synchronized so there is some waste of disk space. I would like to have only one ...
1
vote
1answer
207 views

cd to a name-unknown directory in a known path

I am trying to automate the deployment of a webapp under development that is frequently updated. The webapp comes in the form of a zip file with unknown name, and this directory structure: ...
39
votes
7answers
3k views

cd .. on root folder

Why cd .., typed at root folder, does not warn or fails with an error? I would expect: /$ cd .. -bash: cd: ..: No such file or directory Instead, I'm left at /. Of course, this is since .. does ...
-1
votes
2answers
167 views

FTP clients only showing 9998 folders in a directory with many more

How can I increase the limit of files or folder in linux? Right now when I use any ftp software it shows that there are only 9998 folder in that directory. But I ran a simple php script that would ...
3
votes
2answers
156 views

Path syntax rules

I'm writing a library for manipulation Unix path strings. That being the case, I need to understand a few obscure corners of the syntax that most people wouldn't worry about. For example, as best as ...
6
votes
2answers
214 views

How does one create a directory that can't be seen and can only be accessed via its absolute path name?

I'm working on an assignment on adding time support to a standard UNIX system. Part of it, however, involves securing the location of backup files (which we've set to be at the system root by default) ...
3
votes
1answer
59 views

Where does ext4 store directory sizes?

Where does ext4 store directory sizes? Are they stored in the directory inode? For example, when I run du -h, it returns directories' size instantly, so I don't believe it calculates it at that time. ...
7
votes
6answers
771 views

Is it possible to remove folder prefix from a `ls` command

I am in a bash script and I want to get the list of all files (let say all jar files). I execute the command ls -1 lib/*.jar and I get the output: lib/mylib_1.jar lib/mylib_2.jar ... Is there any ...
16
votes
6answers
2k views

Why do I have to cd out of a deleted directory?

On my server I have a directory structure looking something like this: /myproject/code I normally have an ssh connection to the server and 'stand' in that directory: root@machine:/myproject/code# ...
1
vote
2answers
79 views

Create a user that can only connect to a specific directory

I've created a SSH folder for some friends. I've created the users to log in via SSH, but they connect to ~ how can I set to which folder they can connect? I have a directory called /usbdrv/ which ...
2
votes
1answer
136 views

inotifywait not working when folder is deleted and re-created

I am trying to use inotifywait to monitor a folder: inotifywait -m -r /home/oshiro/Desktop/work_folder The command works and if I create files in that folder, all seems to work correctly. While ...
1
vote
1answer
76 views

List files, directories and executables in current directory

I have php shell and I have function that do just that (but it give me error when I call scandir($path) function because of restriction in php), so I need to use my bash shell to do the same. It can ...
0
votes
1answer
61 views

Mount a dropbox directory without installing the dropbox application

This is most likely to be a duplicate question, but I could not find a simple answer for my problem. My situation is as follows: I have multiple accounts on different computing clusters. I want to ...
2
votes
1answer
141 views

Open multiple directories in different tabs in the same window in CentOS

How can I set my CentOS to be able to open multiple directories in different tabs in the same window? I have already enabled the feature to open the folders in the same window, but this is different: ...
1
vote
2answers
102 views

What is ~/default used for? [closed]

When I connect to my server using a the shell provided by Capistrano it executes ~/default before every command. I can't find out if this is Capistrano related or if this file has some generic use ...
2
votes
2answers
113 views

Symlink all subdirectories in a directory to another directory

I'm trying to symlink every directory in a folder to another folder. For example, in the structure below, I need the subfolders symlinked to folder2. - /home/chris/folder1 -- subfolder1 -- subfolder2 ...