DebianThis forum is for the discussion of Debian Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi, I am running Debian testing on my home PC with kernel 2.6.7-1-k7.
yesterday I started playing with xterm. I run X with my user, in my .bashrc I set TERM=xterm-color and in KDE I can run xterm with no problem. However, I have another user named bbs, and I set up that user with the exact .bashrc (I copied it and chown bbs:bbs). Now, when I set TERM=xterm-color and I su bbs, whenever I run vim to edit a file I get Xlib: connection to ":0.0" refused by server.
But, here the funky thing about it. When I set TERM=linux, I don't get the error in vim! It only happens when I set TERM=xterm-color. I don't understand this. Does anyone here have any experience with this? I've done searches on google for this error and they claim it has something to do with .Xauthority, but I don't think so and here's why. As a test, I deleted /home/bbs/.Xauthority and I shut down X. Then I logged back in as user bbs and ran startx. .Xauthority got generated, and xterm does not give any errors even when I set TERM=xterm-color!
Why does su bbs give errors, but loging in as user bbs not?
In general, dealing with X tends to be difficult. IMO, GNU/Linux makes a great server OS, and I use Debian for this whenever given the chance. But when you try to use it as a desktop, you run into walls that haven't quite been smoothed over yet by time and the community. They may never get smoothed over. Dunno. That's not too bad a thing though -- maybe we'll have Syllable ( http://www.syllable.org/ ) before long for desktop use instead.
Anyway, X is one of these walls. My procedure in dealing with it has always been: keep the setup as simple as possible, and let systems like dpkg-reconfigure do as much of the work for you as possible.
There are various instructions on the web that might help you, including:
1.using the xhost command: "xhost +local:bbs", or
2. using "xhost +localhost", or
2. running "export XAUTHORITY=/home/bbs/.Xauthority" (as which user I do not know). Maybe you can put that line in the relevant user's .bash_profile. Or,
3. export DISPLAY=:0.0 if that variable's not already set.
I don't understand exactly what they all do, but I've run them in the past and if you simultaneously stand on one leg with a macaroni strainer on your head and howl at a full moon while you execute them, they may also work for you.
2. running "export XAUTHORITY=/home/bbs/.Xauthority" (as which user I do not know). Maybe you can put that line in the relevant user's .bash_profile. Or,
You put it in the /root/.bashrc then when you su to root the file is read and the Xauthority is used from the user who did the su of course the /home/bbs in the line above has to be changed to the actual username of the user doing it.
Stephen, thanks for adding that note there. I just dug around and checked
my personal notes on using X, and found that there was a line there about
.Xauthority -- describing just as you did above -- saying "I am quoting
happytux on that one." I haven't touched that doc in way over a year! So
thanks.
johnMG, do you really think this is a reason to scrap linux?
This is something you just get used to.
i have to use different solutions with different programs, with tvtime gksu works best,
with the libranet xadminmenu sux, but it's not a problem.
Syllable looked interesting but seemed to be about as far from completion as ReactOS..
> >
> > maybe we'll have Syllable ( http://www.syllable.org/ ) before long for desktop use instead.
>
> johnMG, do you really think this is a reason to scrap linux?
For server use? Heck no.
For desktop use? Pretty soon, I just don't think GNU/Linux is going to be able to compete with Syllable for desktop use. Syllable is all about ease-of-use and good design. Once users get this in a GPL'd free OS, it's gonna be tough to get them to go back to X11, cups, alsa/oss, multiple GUI toolkits that you can't copy/paste between, and so on.
> Syllable looked interesting but seemed to be about as far from completion as ReactOS..
Those two projects are very different. When building an operating system, you need smart and experienced developers to build it. It's difficult to get real OS hackers to work on an OS like ReactOS which is just copying an OS that most of us in the free software community want nothing to do with.
Contrast that with Syllable, which is getting more and more attractive to hackers due to lack of backward-compatibility cruft, clean design, and the same favorable licensing as Linux.
> Is this UNIX at all?
I think it's mostly POSIX-compatible, so, yes. It uses most of the normal GNU tools you're used to, but has its own kernel (not Linux), and its own GUI front end (not X11). It's got a directory structure like GNU/Linux, and also some simply-named directories for its own stuff as well. It's based on Atheos, and is also a lot like BeOS. All its core parts are all GPL'd.
It's steadily improving and seems to gain more users/contributers with each release, and is currently fairly usable. I think their next task is to really stabilize the API. At that point, I think you'll see more interest from app developers, and then ball will really be rolling.
I have a problem while loggin in as "su -".i tried export and it gave some errors.but if i simply login as "su",i can run any gui apps..expecting help..
Code:
prakash@sarge:~$ echo $DISPLAY
:0.0
prakash@sarge:~$ su -
Password:
sarge:~# export DISPLAY=:0.0
sarge:~# gedit
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
(gedit:9926): Gtk-WARNING **: cannot open display:
First of all, this is not something that simply has not been smoothed out. This is a security feature. You could disable auth, disable remote connections to your X server, and only allow one user to log in at a time. Sure this would be easy, but at this point you may as well use windows. I use debian for security and functionality, while others complain about this because it doesn't work the way they expect, because they expect windows, which has neither.
Now that I got that out of the way.
INSTALL SUX!
It is a wrapper script for su, with the specific purpose of forwarding your DISPLAY variable and xauth cookie.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.