Changing permissions in a Unix directory
Clash Royale CLAN TAG#URR8PPP
I am not able to change permission on a directory I created on the Unix server.
This is how the structure looks
$ ls
engany N832342 N854431 zabbix
$
Now I want to change the permission in N854431 folder so that I can read, write and execute files there.
Reason being currently when I am trying to scp some file from my local to that folder it gives an error "Permission Denied"
When I do this:
$ ls -l
total 16
drwxr-xr-x 3 engany engany 4096 Jan 16 08:46 engany
drwxr-xr-x 3 N832342 N832342 4096 Jan 15 05:30 N832342
drwxr-xr-x 5 N854431 N854431 4096 Jan 16 09:25 N854431
drwxr-xr-x 16 zabbix zabbix 4096 Jan 10 22:51 zabbix
$
I want rwx permission for any directory under N854431.
So I did this:
$ chmod -R ugo+rwx /home/N854431
And now I see rwx permission in N854431
$ ls -l
total 44
-rwxrwxrwx 1 N854431 N854431 8980 Apr 20 2016 examples.desktop
-rwxrwxrwx 1 N854431 N854431 24971 Jan 16 10:14 file.py
drwxrwxrwx 4 N854431 N854431 4096 Jan 16 10:08 web_path
$
However now when I try to send a file from my local to a directory under N854431
$ scp file.py N854431@10.6.121.124:/web_path
gives "Permission Denied" error.
When I do just the directory
$ scp file.py N854431@10.6.121.124:
It is able to send file.py under N854431. But it is not sending it to any other directory under N854431.
What is going wrong
linux permissions python
|
show 2 more comments
I am not able to change permission on a directory I created on the Unix server.
This is how the structure looks
$ ls
engany N832342 N854431 zabbix
$
Now I want to change the permission in N854431 folder so that I can read, write and execute files there.
Reason being currently when I am trying to scp some file from my local to that folder it gives an error "Permission Denied"
When I do this:
$ ls -l
total 16
drwxr-xr-x 3 engany engany 4096 Jan 16 08:46 engany
drwxr-xr-x 3 N832342 N832342 4096 Jan 15 05:30 N832342
drwxr-xr-x 5 N854431 N854431 4096 Jan 16 09:25 N854431
drwxr-xr-x 16 zabbix zabbix 4096 Jan 10 22:51 zabbix
$
I want rwx permission for any directory under N854431.
So I did this:
$ chmod -R ugo+rwx /home/N854431
And now I see rwx permission in N854431
$ ls -l
total 44
-rwxrwxrwx 1 N854431 N854431 8980 Apr 20 2016 examples.desktop
-rwxrwxrwx 1 N854431 N854431 24971 Jan 16 10:14 file.py
drwxrwxrwx 4 N854431 N854431 4096 Jan 16 10:08 web_path
$
However now when I try to send a file from my local to a directory under N854431
$ scp file.py N854431@10.6.121.124:/web_path
gives "Permission Denied" error.
When I do just the directory
$ scp file.py N854431@10.6.121.124:
It is able to send file.py under N854431. But it is not sending it to any other directory under N854431.
What is going wrong
linux permissions python
3
You probably want~/web_path
, not/web_path
– jordanm
Jan 16 at 20:32
when i do this: ssh N854431@10.6.121.124 it logs me to /home/N854431/. Thats why it also sends the file.py to this folder as mentioned last
– Baktaawar
Jan 16 at 20:33
1
When you start a path with/
, that makes it absolute, not relative to your starting location.
– jordanm
Jan 16 at 20:33
Isn't N854431@10.6.121.124: before takes u to /home/10.6.121.124?
– Baktaawar
Jan 16 at 20:37
Do u also know how can I remove write permission for Others now? I added ugo. I want rwx permission in all directories under N854431
– Baktaawar
Jan 16 at 20:39
|
show 2 more comments
I am not able to change permission on a directory I created on the Unix server.
This is how the structure looks
$ ls
engany N832342 N854431 zabbix
$
Now I want to change the permission in N854431 folder so that I can read, write and execute files there.
Reason being currently when I am trying to scp some file from my local to that folder it gives an error "Permission Denied"
When I do this:
$ ls -l
total 16
drwxr-xr-x 3 engany engany 4096 Jan 16 08:46 engany
drwxr-xr-x 3 N832342 N832342 4096 Jan 15 05:30 N832342
drwxr-xr-x 5 N854431 N854431 4096 Jan 16 09:25 N854431
drwxr-xr-x 16 zabbix zabbix 4096 Jan 10 22:51 zabbix
$
I want rwx permission for any directory under N854431.
So I did this:
$ chmod -R ugo+rwx /home/N854431
And now I see rwx permission in N854431
$ ls -l
total 44
-rwxrwxrwx 1 N854431 N854431 8980 Apr 20 2016 examples.desktop
-rwxrwxrwx 1 N854431 N854431 24971 Jan 16 10:14 file.py
drwxrwxrwx 4 N854431 N854431 4096 Jan 16 10:08 web_path
$
However now when I try to send a file from my local to a directory under N854431
$ scp file.py N854431@10.6.121.124:/web_path
gives "Permission Denied" error.
When I do just the directory
$ scp file.py N854431@10.6.121.124:
It is able to send file.py under N854431. But it is not sending it to any other directory under N854431.
What is going wrong
linux permissions python
I am not able to change permission on a directory I created on the Unix server.
This is how the structure looks
$ ls
engany N832342 N854431 zabbix
$
Now I want to change the permission in N854431 folder so that I can read, write and execute files there.
Reason being currently when I am trying to scp some file from my local to that folder it gives an error "Permission Denied"
When I do this:
$ ls -l
total 16
drwxr-xr-x 3 engany engany 4096 Jan 16 08:46 engany
drwxr-xr-x 3 N832342 N832342 4096 Jan 15 05:30 N832342
drwxr-xr-x 5 N854431 N854431 4096 Jan 16 09:25 N854431
drwxr-xr-x 16 zabbix zabbix 4096 Jan 10 22:51 zabbix
$
I want rwx permission for any directory under N854431.
So I did this:
$ chmod -R ugo+rwx /home/N854431
And now I see rwx permission in N854431
$ ls -l
total 44
-rwxrwxrwx 1 N854431 N854431 8980 Apr 20 2016 examples.desktop
-rwxrwxrwx 1 N854431 N854431 24971 Jan 16 10:14 file.py
drwxrwxrwx 4 N854431 N854431 4096 Jan 16 10:08 web_path
$
However now when I try to send a file from my local to a directory under N854431
$ scp file.py N854431@10.6.121.124:/web_path
gives "Permission Denied" error.
When I do just the directory
$ scp file.py N854431@10.6.121.124:
It is able to send file.py under N854431. But it is not sending it to any other directory under N854431.
What is going wrong
linux permissions python
linux permissions python
edited Jan 16 at 20:46
Rui F Ribeiro
39.8k1479133
39.8k1479133
asked Jan 16 at 20:30
BaktaawarBaktaawar
1011
1011
3
You probably want~/web_path
, not/web_path
– jordanm
Jan 16 at 20:32
when i do this: ssh N854431@10.6.121.124 it logs me to /home/N854431/. Thats why it also sends the file.py to this folder as mentioned last
– Baktaawar
Jan 16 at 20:33
1
When you start a path with/
, that makes it absolute, not relative to your starting location.
– jordanm
Jan 16 at 20:33
Isn't N854431@10.6.121.124: before takes u to /home/10.6.121.124?
– Baktaawar
Jan 16 at 20:37
Do u also know how can I remove write permission for Others now? I added ugo. I want rwx permission in all directories under N854431
– Baktaawar
Jan 16 at 20:39
|
show 2 more comments
3
You probably want~/web_path
, not/web_path
– jordanm
Jan 16 at 20:32
when i do this: ssh N854431@10.6.121.124 it logs me to /home/N854431/. Thats why it also sends the file.py to this folder as mentioned last
– Baktaawar
Jan 16 at 20:33
1
When you start a path with/
, that makes it absolute, not relative to your starting location.
– jordanm
Jan 16 at 20:33
Isn't N854431@10.6.121.124: before takes u to /home/10.6.121.124?
– Baktaawar
Jan 16 at 20:37
Do u also know how can I remove write permission for Others now? I added ugo. I want rwx permission in all directories under N854431
– Baktaawar
Jan 16 at 20:39
3
3
You probably want
~/web_path
, not /web_path
– jordanm
Jan 16 at 20:32
You probably want
~/web_path
, not /web_path
– jordanm
Jan 16 at 20:32
when i do this: ssh N854431@10.6.121.124 it logs me to /home/N854431/. Thats why it also sends the file.py to this folder as mentioned last
– Baktaawar
Jan 16 at 20:33
when i do this: ssh N854431@10.6.121.124 it logs me to /home/N854431/. Thats why it also sends the file.py to this folder as mentioned last
– Baktaawar
Jan 16 at 20:33
1
1
When you start a path with
/
, that makes it absolute, not relative to your starting location.– jordanm
Jan 16 at 20:33
When you start a path with
/
, that makes it absolute, not relative to your starting location.– jordanm
Jan 16 at 20:33
Isn't N854431@10.6.121.124: before takes u to /home/10.6.121.124?
– Baktaawar
Jan 16 at 20:37
Isn't N854431@10.6.121.124: before takes u to /home/10.6.121.124?
– Baktaawar
Jan 16 at 20:37
Do u also know how can I remove write permission for Others now? I added ugo. I want rwx permission in all directories under N854431
– Baktaawar
Jan 16 at 20:39
Do u also know how can I remove write permission for Others now? I added ugo. I want rwx permission in all directories under N854431
– Baktaawar
Jan 16 at 20:39
|
show 2 more comments
0
active
oldest
votes
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f494918%2fchanging-permissions-in-a-unix-directory%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f494918%2fchanging-permissions-in-a-unix-directory%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
3
You probably want
~/web_path
, not/web_path
– jordanm
Jan 16 at 20:32
when i do this: ssh N854431@10.6.121.124 it logs me to /home/N854431/. Thats why it also sends the file.py to this folder as mentioned last
– Baktaawar
Jan 16 at 20:33
1
When you start a path with
/
, that makes it absolute, not relative to your starting location.– jordanm
Jan 16 at 20:33
Isn't N854431@10.6.121.124: before takes u to /home/10.6.121.124?
– Baktaawar
Jan 16 at 20:37
Do u also know how can I remove write permission for Others now? I added ugo. I want rwx permission in all directories under N854431
– Baktaawar
Jan 16 at 20:39