LinuxQuestions.org
Help answer threads with 0 replies.
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 02-21-2008, 04:22 PM   #1
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Rep: Reputation: 42
Exclamation can't copy files from root


Ladies & Gentlemen

I am trying to migrate my kmail setup from a desktop to my laptop. I have succeeded in moving all the files and getting the ownership and permissions right I think except for what seam to be account spec files for the servers relating to each email account. Some of the files I had to take possession of as root to be able to copy them to the laptop and the chown -R user:user /a/dir to be able to have kmail on the laptop use them.

The file names for the ones I can't move to the laptop look something like
user@myemail.com:@some.server.net:995

I have taken possession of these files as root on the desktop and save them to a shared folder that I can access from the laptop. From the laptop I can select the files but when I try to save them on the laptop I get an error message that says access denied. This is the root account how come access is denied?

I have looked on google but I didn't find where anyone else was having this problem.

What am I missing?

It must be one of those stupid things. I did spend an hour or so trying to mount my bluetooth adapter as my thumb drive today. Then I noticed I had the wrong usb thingy in my hand. Duh. Boy do I feel stupid.

Thanks.
 
Old 02-21-2008, 05:25 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,962
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
Hmmm ... which method are you using for the "but when I try to save them on the laptop"
bit, which user are you doing this as?


Cheers,
Tink
 
Old 02-21-2008, 05:37 PM   #3
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
I am doing this through Thunar as root. (kmenu>run>thunar as root) I have not tried to do it from the command line.

The other files I had to take possession of as root, I had to save first in a different folder on the desktop before I could copy them to the laptop. But that didn't work for these.
 
Old 02-21-2008, 05:43 PM   #4
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
I thought it might have something to do with kmail being running when I first tried but I shut it down and that didn't change it.
 
Old 02-21-2008, 05:45 PM   #5
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,962
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
How is that network share being accessed? Thunar means nothing to me.
Is it samba, nfs, something else?


Cheers,
Tink
 
Old 02-21-2008, 08:09 PM   #6
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
Thanks Tinkster forgot to mention that thanks before, sorry.

I am accessing the network share via samba. Thunar is a gtk file browser. A lot faster than konqueror.

Thanks
 
Old 02-22-2008, 02:06 PM   #7
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
More info:

I have tried to copy these files onto a usb thumb drive (windows format) and the desktop system won't let me. I can however copy them where ever I want to on the desktop. Still no success copying these (desktop)root owned file to the laptop with the (laptop)root account.

I do understand, I think, about the thumb drive because it's file system has no way to preserve the r/w bits for the files.

Still puzzled as to why the (laptop)root account, which can read the files on the desktop, can't save them on the laptop?

Thoughts?
 
Old 02-22-2008, 02:16 PM   #8
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
More info:

Although I can see the files from as a normal user I can't open them. They are owned by root, must be why. The permissions are reported as [-rw--w--w-]. I can change these on the desktop from root but not from the laptop. I am unable to look at the contents (they are just text files) from root either.
 
Old 02-22-2008, 02:41 PM   #9
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,962
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
Sorry my friend, but you're just confusing me :}

Why don't you try to use scp instead?
Become root on the laptop, go to the location where you
want the files to end up
cd /path/to/target
scp -pr root@desktop:/path/to/files .

And then chown the files on the laptop to the user
they're meant to be owner by.
chown -R user:group /path/to/target/files



Cheers,
Tink
 
Old 02-22-2008, 02:41 PM   #10
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
More info:

I have tried renaming them on the desktop but I still can't copy them to the laptop.

I have opened them in a root text editor and copied the contents to a normal user text editor and saved the file and it disappears into cyberspace somewhere.

There has to be some kind of bit set that I don't know about.
 
Old 02-22-2008, 03:10 PM   #11
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
Thanks again Tinkster

Something must be wrong with the command I am trying to use
Code:
Kingbee:/home/kingbee/.kde/share/apps/kmail# scp -pr root@192.168.0.245:/home/rbees/.kde/share/apps/kmail
because it keeps spiting out the scp usage info.

I have tried the -4 option for ip4 addresses only and get the same thing.

Am I correct in assuming that this will overwrite the existing files?

Thanks.
 
Old 02-22-2008, 03:25 PM   #12
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,962
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
The problem is omitting the . at the end.
Code:
scp -pr root@192.168.0.245:/home/rbees/.kde/share/apps/kmail .
And yes, it will overwrite existing files w/o a warning.


Cheers,
Tink
 
Old 02-22-2008, 04:22 PM   #13
rbees
Member
 
Registered: Mar 2004
Location: northern michigan usa
Distribution: Debian Squeeze, Whezzy, Jessie
Posts: 647

Original Poster
Rep: Reputation: 42
Thanks again Tinkster

I need a . at the end? Never saw that before. I did a little looking on google and looked at a couple of other examples and came to the conclusion that I should be doing this from the desktop and not the laptop where the files needed to end up and I had immediate success without a . at the end.

Thanks again Tinkster for pointing out scp to me. It worked very well. I recopied all of the files for kmail again just to be sure. I did notice as I was looking over the files while chown'ing them that some of them were still owned by the laptop user from the previous attempts. Not a complete overwrite?

Thanks.
 
  


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
Command to copy files/folders but skip bad/corrupt files?? leemoreau Linux - Newbie 2 04-02-2007 02:27 PM
Mepis, copy files to thumb drive, files deleted? vremenno Linux - Newbie 6 09-15-2006 11:21 PM
Downloading files into root or write files to root RaleighRalley Linux - Newbie 2 07-01-2006 10:56 PM
How do I copy a file into root? Cyberian Linux - Newbie 14 07-08-2004 03:59 PM
root files: create as root:root or root:wheel? pcass Linux - Security 1 02-07-2004 04:14 PM


All times are GMT -5. The time now is 05:59 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration