Use this tag for questions about file management and operations on files.

learn more… | top users | synonyms (1)

0
votes
2answers
29 views

How to make partitions with in /home/user/ writable by user?

I have a partition scheme like this: / /home/ /home/user/files/ When logged in as user, I cannot save any files at /home/user/files/. The only solution I can find is to create a new subdirectory as ...
0
votes
1answer
37 views

What dev folder allows you tell the OS to cache something?

Someone told me that there is a sub folder off of dev that basically allows you to tell the OS to keep the contents of that folder cached in RAM. So if I put some files & directories in ...
0
votes
1answer
62 views

How do I delete a file in a read-only directory?

I've got a directory and a file in it, with the directory marked as read-only: $ mkdir directoryname $ touch directoryname/filename $ chmod a-w directoryname I cannot delete the file, even if pass ...
0
votes
2answers
86 views

Getting rsync failures randomly

I am getting the following rsync errors randomly from my capistrano scripts. rsync: stat "/app/test-0.1-SNAPSHOT.jar.SB4uq7" failed: No such file or directory (2) rsync: rename ...
0
votes
1answer
82 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 ...
0
votes
3answers
66 views

Looping the listing files in UNIX

I've given the command: ls -lrt and the listed files and directories are: drwxr-xr-x 4 root root 4096 Feb 2 2014 abc drwxr-xr-x 4 root root 4096 Feb 2 2014 cde drwxr-xr-x 4 root ...
0
votes
1answer
57 views

Partition is out of space

When I was trying to resolve the issue as seen in this question, I figured out that a specific partition is out of space. I have a specified folder which I allow all ftp uploading of multimedia files ...
0
votes
1answer
427 views

LS Command output to file [closed]

I want to capture to a file the output of the ls command ls >> lsOutput.log This one works if executed in the command line. But when put inside a shell script (lsOutput.sh), returns ...
0
votes
1answer
180 views

Auto detect new files and upload them [closed]

I'm starting work on a new project and I need to know the feasibility of the end-result. I need a lot of things to happen automatically. Detect if a new file has been added to a folder Login to a ...
0
votes
1answer
99 views

How can number of subdirectories and files be determined from ls -ld command? [closed]

How can number of subdirectories and files be determined from the output of using ls -ld command? I realize that this command only lists the directories.
0
votes
1answer
100 views

In shell script, execute a command only if the source is newer than the target

I'm looking for a simplified version of this: dep=0 if [ ! -e targetfile ] then dep=1 elif [ targetfile -nt sourcefile ] then dep=1 fi if [ $dep -eq 0 ] then echo "Already up to date" ...
0
votes
3answers
5k views

need to move files to different folder based on the creation date [duplicate]

I have set of files created from Monday to Friday.. a -- > 08/20 a1---> 08/21 a2---> 08/21 a3---> 08/21 a4---> 08/22 a5 --> 08/23 I need to move only 08/21 file to diffrenet ...
0
votes
2answers
1k views

Ubuntu : unable to copy file to dir created under same credentials

I am Windows 7 remoting to Ubuntu 12.04.2 LTS I am new to Ubuntu ( and *nix in general ) and need to understand how permissions are assigned to newly created dirs. Via Putty ssh session : $bash ...
0
votes
1answer
44 views

Keyboard shortcut to switch files in one Emacs instance?

I've multiple files opened in an Emacs client. Right now, to toggle between files, I've to click on the file name at the bar below in the editor. Any keyboard shortcuts for switching between files?
0
votes
1answer
520 views

Transfer 150GB of files from an old MacBook Pro with Ubuntu 13.04 Live DVD

My girlfriend's old MacBook Pro 2009 (5,4) stopped working. I have tried several times to reinstall OS X, but could not do so. There appears to be something really really wrong with the OS. Since she ...
0
votes
2answers
2k views

Solaris 10 modified time

In Solaris 8, when we access the file, the access time changes but modified time remains same. But in Solaris 10, we see that both access and modified time changes when accessing the file. We checked ...
0
votes
1answer
130 views

Having trouble executing a compiled C program

I am running an Ubuntu v10.04 through VirtualBox. To test the persistence of files I create in the virtual machine, I wrote a very basic C program. When I shutdown the virtual machine and restart it, ...
0
votes
2answers
60 views

Knowing if a directory is modified

I have a server online and I am wondering if there's a way to know if some file on the server is modified or a new file is added to certain directories. For example, I have this ...
0
votes
2answers
2k views

How to find last deleted files on OpenSuse?

I didn't lock the screen on my OpenSuse Linux and let my girlfriend do all evil things when I was sleeping. Is there a way to find out if she deleted any files from my PC? I was looking at the "Date ...
0
votes
1answer
124 views

Cent OS 6.3 Hidden files in shell

I need help, I want to be able to check whether a file is hidden or not in Cent OS 6.3. These are often referred to as (dot) files but I can clearly see Cent OS 6.3 handling these by appending a ...
0
votes
1answer
1k views

How to copy files nested in directories that match a pattern?

I'm looking to copy files from subdirectories that match this pattern vendor/plugin/*/tasks/*.rake into a folder lib/tasks I think that this could be done several ways, but wanted to see if a ...
0
votes
1answer
24 views

What has priority - owner/user vs group permission? [duplicate]

I have just run into the case in which the owner-group of a file has more permissions than the owner-user of a file. user1@pc:/tmp$ ls testfile -l ----rw---- 1 user1 user1 9 Okt 16 13:16 testfile ...
0
votes
1answer
17 views

file command to show “for GNU/LINUX 2.x.x” also for shared libraries

Using the command file my_executable_binary I get information like this: ELF 32-bit LSB executable, ARM, version 1 (SYSV), for GNU/Linux 2.6.34, dynamically linked (uses shared libs), stripped ...
0
votes
1answer
40 views

File tranfer from the server

I want move (not copy with scp) my file from the server to the local repository and finally delete it on the server after transfer. I use next command from the repository, where I want have the file: ...
0
votes
2answers
50 views

Remove by date in Shell Script

I have a shell script that creates a backup of a database. I would like to keep the last 7 days for files. What is the syntax I need to remove files in a directory by date or can I keep the newest 7 ...
0
votes
1answer
36 views

how to change where a symlink points [duplicate]

Can you tell me what is this in red marker area. ? and if want to change /media/files/tb-prod/files to some other path, then how it will be .. ?
0
votes
1answer
48 views

File not found: Beautiful Soup

I am trying to run a program that I downloaded in Ubuntu latest version, but I continue getting an error everytime I try to run the program. It says: File Not Found: BeautifulSoup So in order to ...
0
votes
5answers
342 views

Move files to multiple folders [closed]

I've searched for this function, and there are lots of answers, but I haven't been able to find anything that works for me. I have a folder with about 30,000 files, and I want a terminal command or ...
0
votes
1answer
247 views

Accessing file from the Windows host in a VirtualBox virtual machine

I am running Ubuntu 14.04 as the guest operating system in a VirtualBox virtual machine. The host runs Windows 8 (24GB). I want to access a folder of the host inside the guest. Since the source is ...
0
votes
1answer
55 views

How do I search for files from the gnome GUI in debian?

I sometimes spend time in the standard classic gnome GUI in debian wheezy, and today I wanted to search for files containing some text in a certain folder. I tried to do it the windows way by going ...
0
votes
1answer
51 views

Give a user the permission to access files in a directory

I have mounted a volume from NAS storage to my Solaris 10 machine using NFS. I want to give read/write permission for a user to the directories and subdirectories and files. I have tried setfacl -m ...
0
votes
1answer
39 views

Is it viable to have a file with 700 permissions?

I have been wondering about the following thing: Consider Pc A. Pc A has n users. There is a folder with one file per user. There is some sensitive information for each usere there, so you don't ...
0
votes
1answer
48 views

setfacl remove all write access

I want to remove all write access to files & directories for any user or group while preserving other permissions. Is this possible?
0
votes
2answers
235 views

using inotify to monitor access to a file

I would like to have a trigger and when a particular file is accessed by some process, I would like to be notified (i.e. a script should be run). If I understand correctly, this could be achieved with ...
0
votes
1answer
1k views

Transfer files from CentOS VM VirtualBox to Windows host machine

How can I transfer the scripts and text files I've created in my CentOS environment and put it in my host desktop (Windows 7)? I've tried using ftp but it needs to configure the routers to use vsftpd, ...
0
votes
1answer
53 views

Execute scripts without decrypting them

I have a set of scripts (bash, ruby, python) and want to put everything into a container like file so I can deploy this container on a lot of servers. This scripts need to protect from accessing other ...
0
votes
1answer
32 views

Why does “file foo.css” and “file bar.css” have different outputs?

For example, executing file styles.css outputs: styles.css: asssembler source text whereas file bar.css outputs: bar.css: ASCII text Even better, is there a way to convert my file styles.css to ...
0
votes
1answer
83 views

. (dot) shows up as path separator [closed]

I'm hunting a really strange bug: arian@orel:~$ ls ._cache.<tab><tab> Display all 205 possibilities? (y or n) ._cache.apt-file/ ._cache.chromium/ ._cache.chromium.Default/ ...
0
votes
2answers
148 views

Make file in linux readonly

Is there a way to make a file readonly permanently in linux. Or can I put a password to a file to make it readonly, then apply that password again to change its permission, or before they can alter ...
0
votes
1answer
18 views

Relocate file into subdirectory

I'm bit new to Unix. Please help with below question though it may sound very simple. How to relocate file1 into subdirectory dir1?
0
votes
1answer
138 views

Passing multiple scripts to shell over ssh

I have a somewhat lengthy script which sources other scripts to include the functions there. I'd like to execute this script remotely via ssh. Now I thought to make one script file of it (without ...
0
votes
1answer
73 views

Check multiple directory properties

I'd like to make this test as fast as possible: (Bash) if [[ -d $directory_path && -r $directory_path && -x $directory_path ]]
0
votes
1answer
60 views

Permissions not extended to user in minecraft group [duplicate]

I have a directory, under /srv: drwxrwxr-x 3 minecraft minecraft 4096 Dec 30 06:23 minecraft Owned by user minecraft, group minecraft. Group has read/write/search permissions. I have a user, ...
0
votes
2answers
109 views

How can I for example list five largest files in /usr/lib -directory?

How can I for example list five largest files in /usr/lib directory? Please also add some minor explanation for each bit of code that you are using.
0
votes
1answer
291 views

How to hide file size using ls command

I need to list some files in a directory using the ls command, but I need to also to hide the file sizes. How can I do that with the ls command?
0
votes
1answer
204 views

Get a clean list of files transferred from rsync

I'm trying to get an itemized list of files transferred by rsync. Using the -i and --out-format options, I'm instead ending up with output that looks like this: 3HMP1MO_001.tif 974.68K 100% ...
0
votes
1answer
117 views

Linux commands to fetch all files,size and path of files from all directories and subdirectories

Can anyone please guide me, how do I use Linux commands in PHP code to fetch all files names and their size and path of files from all directories and subdirectories. I am running a scan code. where ...
0
votes
1answer
59 views

Get the most recent backup files [duplicate]

I'm googling for this, but the terms are so generic I'm getting way too many false positives, so what the hey, I'll ask here. I'm sure there's a simple answer but I don't generally script in *nix. ...
0
votes
2answers
192 views

How to recover a SD card? [duplicate]

I accidentally deleted my SD card photos. I purchased a software call wondershare photo recovery and card recovery. I am able to recover back 50% of my photos. But I got some strange issues here. ...
0
votes
1answer
35 views

File inventories and logrotation

I want to collect a huge amount of data files on my actual netapp storage with the command file - f /path... > logfile.txt. Through the huge data amount, the size of the logfile will be critical. ...