Do You Have To Have Execute On A Directory To Be Able To View Contents In It?

hi guys im a little confused

read privilege on a directory means i can list the contents
write means i can save,edit and delete files in that directory
but then it says execute is like a light switch,if its off (no execute) you will not be able to view items in the directory

so do you have to have rwx on a directory to be able to use it fully?
if you have rw- as the owner will you not be able to view or change
into subdirectories within that directory?


Similar Content



Connecting To Specific Directory With Filezilla

Hello, I have an embedded linux device. I can connect to the device and I can upload or download files. No problem with this. But, at first connection, I want to connect to "/" directory instead of "/root". In the device file system, there are files ssh_config and sshd_config under /etc/ssh directory. I think I have to do something with these files but I don't know what.

I don't exactly know what mean "/root" and "/" directories. I think that the real root directory is "/" directory which is empty but when I connect with filezilla, the "/root" directory is the default so I had to go back to / directory everytime.

Delete A Directory Tree From SFTP Server

Hi Experts,

Is there a way that i can delete selected directory trees on sftp server. Directory is only getting removed if it is empty. I am able to sftp & scp on the server to transfer the files.

Please help here!

VijayB

Installing Gnuplot Version 5.0

Hi there. I have a problem installing the newest version of gnuplot which is 5.0. I downloaded it from this website (sourceforge): a source tarball. The Ubuntu 12.04 archive manager in my laptop placed it in the directory /home/alex/gnuplot-5.0.0.tar. I opened the directory/folder with a click and began reading manuals. The install procedure (read INSTALL.gnu) calls for issuing this command:

Quote:
1. `cd' to the directory containing the package's source code and type
`./configure' to configure the package for your system. If you're
using `csh' on an old version of System V, you might need to type
`sh ./configure' instead to prevent `csh' from trying to execute
`configure' itself.
It is impossible to get to the directory gnuplot-5.0.0.tar via a terminal. If I type cd gnuplot-5.0.0.tar it says that this is not a derectory. If I omit .tar it does not recognize the name at all. I tried to rename it but after that I could not open it even with a click.

What shall I do?

Thanks, - A.

Script To Recursively Enter Subdirectories And Rename Files Sequentially From Scratch

I am new to Bash scripting.

I have a main directory called Photos which has many subdirectories like People, Places and Things. Each of these subdirectories is populated by other subdirectories and lots of JPG photo images.

The digital cameras name the files in a way that is difficult to manage with web hosting.

I would like to go to each directory and subdirectory and rename the photos 1.jpg, 2.jpg, 3.jpg, etc. so that I can use a simple XML template to access them by specifying only a hosting directory.

I tried to use the following script:

#! /bin/bash

cd /home/paul/test

find . -name "*.jpg" -print0 | rename -v 's/.+/our $i; sprintf("%d.jpg", 1+$i++)/e' * -vn

exit 0

It successfully renames all of the files in all of the directories, but it does not restart the numbering for each new subdirectory. So first it goes through Photos and renames the three JPG files there 1.jpg, 2.jpg and 3. jpg, and then it opens the first subdirectory People and names the three JPG files there 4.jpg, 5.jpg and 6.jpg. Next it moves to the next subdirectory and continues sequential renaming until it is done.

I want it to restart sequential renaming with each new subdirectory, so that after renaming the three JPG files in Photos to 1.jpg, 2.jpg and 3.jpg, it moves to the first subdirectory and renames the JPG files there starting with 1.jpg again.

That way I use the links 1.jpg, 2.jpg, 3.jpg, etc in the XML template and just change the directory name to download the photos from the web.

Thanks for any help you can give me.

Soft Link

Hello everyone!
I wonder if you can help me with the following:
If you have the following directory and subdirectories,
UDIR1 ---MAIN DIRECTORY
under UDIR1 there is two subdirectories: UDIR11 AND UDIR12
under UDIR11 there is a subdirectory: UDIR111
under UDIR12 there are two subdirectories: UDIR121 and UDIR122
Given the above scenario:
1- How to create a soft link of the directory UDIR111 under the directory UDIR12, and then how do you name the soft link UDIR111-sl

Thanks so muchhhhhhhhhh to anyone who can help!!

Regards,
Carlos

What Exactly Is PATH

books say that PATH variable contains the locations where the shell searches the commands to execute them.

I created a shell script and saved it in /home/user/Downloads directory and then i ran this script from the /home/user/Downloads directory. It did not execute.

however when i did set the path
export PATH=$PATH:/bin/sh within /home/user/Downloads directory, the shell script executed. Does it not mean that PATH variable is holding the locations of the shell program rather than the commands that are to be executed?

everytime i have to give the location of the shell i.e /bin/sh in the PATH variable no matter from where i am executing my script

Hidden Folders And Files Become Viewable In Home Directory

Hi guys,
.
For no apparent actions from me, hidden folders and files show
in my /user/home directory, they are as follows:-

folders:
.adobe .cache .config .cups .filezilla .gimp-2.8 .gnupg .gphoto .gstreamer-0.10 .icedtea .java .local .macromedia .mozilla .pki .thumbnails

Files:
.bash_history .bashrc .esd_auth .ICEauthority

In my / directory
File: ./readahead

Seeking help to verify the above folder and files are not from a harmful source or application?

If they do not post any thread to the system, how can I conceal
these folders and files, so that they don't show up any more in
my home and / directory ?

Many thanks.

Rmdir -r

hi guys, im trying to get rid of a non empty directory. i have researched it online and it basically says that the command would be sudo rmdir -r filename
it keeps coming back with invalid option for r

what am i doing wrong?

the directory is in the home directory along with the documents, videos, download etc and i am in the home directory. i tried putting a text file there to make sure i am in the right path and it deleted it with rm so the path is correct.

i understand that i can do it with the gui but im trying to learn the terminal for the next forty years.

any suggestions would be greatly appreciated.

More Command

hi guys, im having terminal trouble.

i have a libre word file called lintest.odt in the Documents directory (folder). I want to move it to the Libre directory (folder).

Desktop Downloads Libre Pictures Templates
Documents home Music Public Videos


from the root directory i typed cd Documents and then pwd and I got
/home/francis/Documents
i then typed ls and i got lintest.odt

I then typed mv lintest Libre and it says

mv: cannot stat ‘lintest’: No such file or directory

what am I doing wrong?

when i try to see the contents of the lintest file with more lintest
I got ~/Documents$ more lintest.odt
PK
�F^�2^L'
--More--(0%)
and then it locks up the terminal.

im obviously doing something dreadfully wrong.

Using Find And Pipe To Tar

am trying to use tar in combination with find, the goal is to all files in /export that have been modified in the last 24 hours (back up purposes), then tar them so I can untar on the backup server, updating just the modified files.

Perhaps there is a better way, however, I have tried using cpio but the problem come in when I copy to the NAS drive (NTFS) I lose all my owner/group and permissions. I have found that if I tar the files, then copy them to the NAS, when I untar on the server, it will retain the owner/group and permissions.

So… here is what I have tried:

First, I use the find command to see what files should be in the tar archive.
Code:
/export $ find . -depth -mtime 0 -print
./file4
./file3
.

Ok, that looks right, now I will try to pipe that in to tar
Code:
/export $ find . -depth -mtime 0 -print0 | tar -czvf backup.tar.gz --null -T - 
./file4
./file3
./
./share/
./share/pdf/
./share/pdf/penny-2014-09-03-11:41.30.pdf
./share/pdf/penny-2014-09-03-14:25.17.pdf
./share/pdf/penny-2014-09-03-11:24.36.pdf
./share/pdf/penny-2014-09-03-14:37.12.pdf
tar: ./share/pdf/.directory: Cannot open: Permission denied
./share/pdf/penny-2014-09-02-14:52.06.pdf
./share/pdf/penny-2014-09-03-12:18.43.pdf
tar: ./share/PDF: Cannot open: Permission denied
./share/file3
tar: ./share/.directory: Cannot open: Permission denied
./dir1/
./dir1/file1
./file4
./file2
./file3
tar: ./.directory: Cannot open: Permission denied
./list
tar: Exiting with failure status due to previous errors

It seems that it is trying to tar all the files in that directory. When I view the files in backup.tar.gz all of the files from /export are in there not just the modified ones