LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-23-2005, 04:52 PM   #1
preacher.ca
LQ Newbie
 
Registered: Nov 2005
Location: Regina, Saskatchewan, Canada
Distribution: MDV2006
Posts: 5

Rep: Reputation: 0
Lightbulb Load kde profile from /mnt/removable/user instead of /home/user


here is what i want to do:
rather than my user profile being stored and loaded from /home/user, i want my user profile to be stored on my usb flash drive (1gb) which automatically mounts itself as /mnt/removable.

why i want to do this:
well in theory, if my profile is loaded to my usb flash drive which now makes it portable, i can now have a "roaming" profile sort of speak... so that any computer i go to with KDE and my user login script which points to the usb flash drive for my user profile, i can login anywhere with my user profile like as if i was on a domian network. not only that, but it would seem to be more secure cause all my user info is stored on this flash drive that i keep on me.

actions i have taken:
at first i figured how hard could this be... so to be safe i created a test user "joe" and edited the user profile in /etc/passwd from being "/home/joe" to "/mnt/removable/joe". i logged out of "jim", and logged in as "joe". well right off the start kde failed to load with the following errors:
-interprocess communication failed
-check that the "dcopserver" program is running!
-no write access to $home directory
from here it kicked me back to the kde login screen. so logged into "jim" and check the permissions of /mnt/removable and turns out it was running as jim jim. so i unplugged the flash drive, logged out of "jim" and at the kde login screen plugged in the flash drive, remotely logged in and checked the ownership of the drive... this time it was root root. so i tried logging in again as "joe" same errors.

next i changed the login of "joe" in /etc/passwd from /mnt/removable/joe to /home/joe, logged in as "joe", then logged out. i logged in again as "jim" and su to root and tried moving /home/joe to /mnt/removable. however there was errors in transfering the files to the flash drive. so thinking if root can't move the files then something isn't right here.

after this, i begun my endless search on the net for something like this... cause i can't be the only one who thinks it would be cool to store his user profile on a usb flash drive and have a kinda roaming profile that he can log in with at home or work??? but to my surprise nothing... there was backing up to a flash drive, how to mount a flash drive etc... nothing that i found related...

so my last attempt now is to place an SOS and see what comes to me...

so first off is this even possible???
if so... what am i missing in kde to allow for it to point to this drive and be able to write to it as a different user???
is there something in /bin/bash that i need to add???

just a note... i am not trying to backup my profile like documents or desktop, i can do that from kde's control center, i want to LOAD my complete profile from my usb flash drive, .kde and all...

some specs... i am using mandriva 2006 with the kde 3.4.2. ummm hardware wise although i don't think its the problem, is a laptop with a P4 3.o ghz chip, w/ 512 ram and ati9600 vid card... oh yeah, the usb flash drive is a sandisk micro cruzer 1gb.

thanks for your time in this and any comments are greatly appreciated. if this has already been addressed, then sorry for wasting your time and could you send me the link(s) that will point me in the correct direction. Jim!
 
Old 11-23-2005, 06:06 PM   #2
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
You'll need your flash drive formatted with a *nix file system, like ext2/3. Then you can really set the permissions, create named pipes, sockets, etc.
 
Old 12-01-2005, 07:53 PM   #3
preacher.ca
LQ Newbie
 
Registered: Nov 2005
Location: Regina, Saskatchewan, Canada
Distribution: MDV2006
Posts: 5

Original Poster
Rep: Reputation: 0
alright what i got so far from the last post:

I formatted the usb flash drive by doing the following:
1)first i formated the flash drive as ext3 by using the following as root:
#mkfs -t ext3 -c /dev/sda1
//mkfs(make file system) -t(select what file system you will use, in my case ext3) -c(checks the drive for bad sectors) /dev/sda1(the location of the usb flash drive device)
2)next i mounted the flash drive using the following as root:
#mount -t ext3 /dev/sda1 /mnt/removable
//mount(mount device command) -t(select what file system to mount as, in my case ext3) /dev/sda1(location of the usb flash drive device) /mnt/removable(location of where you want this device to be mounted as)
3)i checked /etc/fstab to make sure it was mounted and sure enough it was.
4)i then gave the mount full user access by doing the following as root:
#chmod 777 /mnt/removable
5)i configured user "joe" to have his login point to /mnt/removable
6)logged out, logged in as "joe" and it worked... i was able to login as "joe", desktop came up and it worked just fine. i made some changes... logged out, logged in, and they stayed.

now for my problems:
1)is there a way to mount the usb flash drive on boot up? it seems to only mount itself once i login as a regular user on the computer... after i login say with "jim" and logout and login as "joe" with the usb flash drive, then the user can login normally... if i don't, then i get the error "kde failed to load"(which is good in the respect that i don't want peeps to be able to login without the usb key with their profile)
2)is there a way to automatically mount the usb flash when you are at the login screen? another test i did was to start up the pc without the usb flash drive, then when it was at the login screen, insert the key and login... well it didn't mount the usb flash, until i logged in with a profile on the hd first. also, if i login as a user on the hd, log out, then insert the usb key, and try to login as "joe" same problem occurs.
3)can i also partition the usb flash to have vfat partition and an ext3 partition? i would also like to store some files on the usb flash so that i can go to a winblows pc and transfer docs from one pc to another. would it be better if i left it as a vfat file system(or another file system that both winblows and linux can read and write to), that way i can still access all of my user docs through winblows rather than having a partition to transfer between them???

thank you again for your time in this matter... i am currently writing up a tutorial for creating roaming profiles using usb keys. I am also going home tonight and going to setup my linux box there and test out logging in with a profile from my usb key... i'll let you know of my results... Jim!

Last edited by preacher.ca; 12-02-2005 at 01:09 AM.
 
Old 12-02-2005, 03:00 PM   #4
preacher.ca
LQ Newbie
 
Registered: Nov 2005
Location: Regina, Saskatchewan, Canada
Distribution: MDV2006
Posts: 5

Original Poster
Rep: Reputation: 0
k, doing some more searching i came across this article which helped me solve the partitioning...
usb flash memory how to

i have also been reading that by editiing /etc/fstab, that on boot up it should recoginize my device??? i will explore and test some more, and i will post my fstab if i can not resolve what is going on...

if any one has any further thoughts, please let me know... thanks. Jim!

Last edited by preacher.ca; 12-02-2005 at 03:03 PM.
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
user home dir doesn't create when new user add dev_mohamed Linux - Software 3 01-12-2007 01:08 AM
Completely hosed my kde user profile jdier Linux - Newbie 3 12-14-2004 09:17 AM
PHP List /home/'user' then finger 'user' Caboose Programming 1 09-22-2004 04:12 AM
user mounting and using removable hd NonSumPisces Linux - Newbie 4 08-14-2004 04:35 AM
Can't Load KDE for USER ClericPreston Linux - Newbie 6 07-01-2004 10:51 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 10:05 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