Solved

No xinitrc file for users - I want root to be the user

Posted on 2004-08-23
7
484 Views
Last Modified: 2010-05-18
OK, when I remote into my linux box as root, I want to be able to start the xWindow on start up.  I do not have a xinitrc file, do not know what's supposed to be in it aside from the startx command and do not know where to put it so that any user who logs on gets the windows x.

Can someone help me?  Thanks!

0
Comment
Question by:foreverdita
  • 3
  • 3
7 Comments
 
LVL 5

Expert Comment

by:willy134
ID: 11874575
what distribution of linux are you using?  What do you want to start?  How are you remoting into your box?  Are you do xdmcp queries?

Try this put

startkde

in a file called .xinitrc in your home directory.
0
 

Author Comment

by:foreverdita
ID: 11874634
Please forgive my ignorance - I have never used Linux before.  Do I name the file .xinirtc?  If so, how do I create that file using a linux command?
0
 

Author Comment

by:foreverdita
ID: 11874647
I want to start windows x - it says to put this line in my .xinitrc file, which I do not have.

/usr/share/xpde/bin/startxpde

0
Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

 
LVL 5

Expert Comment

by:willy134
ID: 11875349
yes name the file .xinitrc

Just open up and editor and do it.

vi example

vi .xinitrc
---it will start vi (a console based editor)
then type in

i                                     ----starts insert mode
/usr/share/xpede/bin/startxpde

escape button then type :x (colon x)
that should create the file for you.
0
 

Author Comment

by:foreverdita
ID: 11877387
OK, I did that.  And now when I go to the box, it should give me the xpde, correct?
0
 
LVL 1

Expert Comment

by:ttimonen
ID: 11882302
You don't really want to run X session as root.
0
 
LVL 5

Accepted Solution

by:
willy134 earned 500 total points
ID: 11883713
ttimonen is right you don't want to do that....

However, we can't stop you.

now if you are running an xserver on the machine you are logging in from you can log in and hopefully xpde runs.

If you are running from windows you might want to look into vnc.  http://www.realvnc.com

then log into your linux box and run vncserver  (set up password)
then kill it with
vncserver -kill :1
then go to your .vnc directory and edit the xstartup file to point to xpde instead of twm
then run vncserver again

from your windows machine run vncviewer adn connect to
youlinux.box.domain:1

that should be what you want.

Just be very careful.  Root has a lot of power and linux gives you plenty of rope to hang yourself.

I usually run su or sudo
su will let you change a terminal session to a root terminal session and sudo will let you run program with root permissions.

look at /etc/sudoers to see how to set up sudo


good luck
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

If you use Debian 6 Squeeze and you are tired of looking at the childish graphical GDM login screen that is used by default, here's an easy way to change it. If you've already tried to change it you've probably discovered that none of the old met…
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…

778 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question