Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Quick Fix | 12 comments | Create New Account
Click here to return to the 'Quick Fix' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Quick Fix
Authored by: vonleigh on Apr 30, '02 03:57:30AM

Hello,

I knew fink had created a few users on my system, didn't know about the home directories being / though. For a quick fix read on.

You can list your users using the following command:

% sudo niutil -list / /users

Then you can see their home directories by doing:

% sudo niutil -list / /users home

You'll see which users have as their home just /. To change these just run the following commands:

% mkdir finkusers #create a dummy finkusers folder wherever you want it.
% sudo niutil -appendprop / /users/mysql home "/<path>/finkusers/"
% sudo niutil -appendprop / /users/news home "/<path>/finkusers/"
% sudo niutil -appendprop / /users/pgsql home "/<path>/finkusers/"
% sudo niutil -appendprop / /users/games home "/<path>/finkusers/"
% sudo niutil -appendprop / /users/canna home "/<path>/finkusers/"

Making sure to replace <path> with the proper path for the directory. For security purposes I made the folder "finkusers" owned by root.



Vonleigh



[ Reply to This | # ]
Re: Quick Fix
Authored by: bjn on Apr 30, '02 09:28:10AM

If you only do "-appendprop" you end up with two values for the home property, the old value / and the new value you provided, and so the name service (getpwnam/getpwuid) still says that / is the home directory (it must pick the first one).

To get this to work, I had to also add a "-destroyprop" -- I don't know if that's the "right way" but it worked for me. So:

% sudo niutil -destroyprop / /users/<login> home /
% sudo niutil -appendprop / /users/<login> home <path>



[ Reply to This | # ]
Quick Fix
Authored by: chvid on Jun 23, '02 04:19:30PM

I found that all I needed to do was change the UID number of the new Fink-created mysql user to that of the "old" mysql user, which I determined by looking at the owner of the files in the /usr/local/mysql/bin - they belonged to user "504" instead of "mysql". After I did that, MySql started fine...



[ Reply to This | # ]