LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-14-2013, 01:28 AM   #1
rhcekumaran
LQ Newbie
 
Registered: Jun 2013
Posts: 4

Rep: Reputation: Disabled
Question File & Folder Permission and Ownership permission error in Cloud storage.


Hi ,

I have configured a cloud storage in existing centos server ......

I have the fstab entry as ..

vim /etc/fstab

//503037.cloud.storage.gogrid.com/503037 /mnt/cloudstorage cifs file_mode=0666,dir_mode=0777,uid=apache,gid=apache,userid=908978,passwd=ertbghshsa;

then i have given the mount command to check the mount point its ok ..no error..

While moving the datas to the storage...using the command...

# scp -rp --preserve stgkb_1406.tgz /mnt/cloudstorage

its gives error...

cp: failed to preserve ownership for `/mnt/cloudstorage/stgkb_1406.tgz': Permission denied

even after moving the data ownership and file $ folders permission is different ...like this..

-rw------- 1 10812 bin 5.8G Jun 14 10:30 stgkb-2013.tgz


please help me how to move the data with the ownership and file or folder permission as it is...
 
Old 06-14-2013, 02:50 AM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 7.7 (?), Centos 8.1
Posts: 18,166

Rep: Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680
Probably because the uid/gid & user/group names are different between the systems.
More to the point, regardless of the user/group names, the files are moved by uid/gid (by num) and that name/num match probably doesn't exist identically on both systems.
 
Old 06-14-2013, 04:12 AM   #3
rhcekumaran
LQ Newbie
 
Registered: Jun 2013
Posts: 4

Original Poster
Rep: Reputation: Disabled
Actually i am moving the files within the same server to additional cloud storage...which is mounted on the system.
 
Old 06-14-2013, 04:41 AM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 7.7 (?), Centos 8.1
Posts: 18,166

Rep: Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680Reputation: 2680
Are you using scp or cp? You show scp as a cmd, but a cp error.
If the storage is mounted within the same machine, cp should be sufficient.

Actually, looking closer, you've got a mount of type 'cifs', which would indicate MSWin (probably NTFS).
The Linux filesystems and ntfs have different ideas/concepts about 'ownerships/permissions', so this isn't unexpected.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mkdir throws Permission Denied error in a directoy even with root ownership and 777 permission surajchalukya Linux - Security 14 09-03-2012 08:34 AM
file permission and ownership johnyhasan Linux - Newbie 2 07-17-2012 04:18 AM
Restore copy folder&file permission aiushtha Programming 3 12-21-2010 09:02 AM
File permission, change ownership revenge80200 Linux - Newbie 2 03-02-2008 01:02 PM
scp - peserve file ownership and permission eyt Linux - Newbie 6 10-24-2003 03:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:27 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration