Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

sudo preserving X



This works for me:

ssh as myself
sudo -H -s -u root
xauth merge /home/kressin/.Xauthority

You might have to play with permissions on the user's .Xauthority file / homedir.

-Dan

--- On Thu, 12/16/10, Jerry Feldman <gaf-mNDKBlG2WHs at public.gmane.org> wrote:
> Currently, if I want to change my
> user id and run a X application,
> things don't work with sudo.
> Ex:
> X connection to localhost:14.0 broken (explicit kill or
> server shutdown).
> 
> The way we work is that users use putty from Windows to log
> into the
> Linux servers. Unfortunately, we have a common user name
> that they all
> can use (against my better judgement). I would prefer them
> to log in
> under their own user names. Additionally, they can set
> their umask to
> 022 so that everyone in the group can work with those
> files. This is
> more the way things should be done in Linux.
> 
> But, a lot of files are currently owned by this common
> user, and as a
> first step I wanted to disallow logins on this and use sudo
> -u.
> 
> It appears that sux would work, but I would prefer to keep
> the current
> sudoers.
> 
> -- 
> Jerry Feldman <gaf-mNDKBlG2WHs at public.gmane.org>
> Boston Linux and Unix
> PGP key id: 537C5846
> PGP Key fingerprint: 3D1B 8377 A3C0 A5F2 ECBB? CA3B
> 4607 4319 537C 5846
> 
> 
> 
> -----Inline Attachment Follows-----
> 
> _______________________________________________
> Discuss mailing list
> Discuss-mNDKBlG2WHs at public.gmane.org
> http://lists.blu.org/mailman/listinfo/discuss
> 


      







BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org