LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Ubuntu: kind-of-windows doesn't start (https://www.linuxquestions.org/questions/linux-newbie-8/ubuntu-kind-of-windows-doesnt-start-399838/)

ursinus 01-05-2006 09:59 AM

Ubuntu: kind-of-windows doesn't start
 
Hi,

I've a problem with my Ubuntu 5.10 version. The kind-of-windows doesn't start. While the computer is running a startup, it opens only a terminal. I mean that the computer remains in kind-of-Dos mode and asks the login. I can log in (as in terminal) but I cannot proceed. As far as I know there isn't any kind of "win"-command for Linux, or is there?

With Best Regards,
Ursinus

valencequark 01-05-2006 10:03 AM

I have absolutely zero experience with Ubuntu, but it sounds like your X-window session isn't starting. the command startx should do the trick.

ursinus 01-05-2006 10:52 AM

Quote:

Originally Posted by valencequark
I have absolutely zero experience with Ubuntu, but it sounds like your X-window session isn't starting. the command startx should do the trick.

Thank you very much, it did start. As the question seems to be rather common by nature, can you tell me how could it be possible to make the bloody computer the run the command also in startup. There must be some sort of autoexec.bat or config.sys file also in Linux.

Ursinus

ursinus 01-05-2006 11:55 AM

While waiting the answer I would like to widen my question a bit. I would like to edit kind-of-autoexec.bat and kind-of-config.sys files of my computer in order to make few tricks at the startup. Is it possible and how, or are the kind-of-files become too complicated compared to good old Dos-times?

mcmillan 01-05-2006 07:43 PM

Normally by default ubuntu should take you to the graphical interface, but it seems like isn't working for some reason. I'm giving directions assuming you're using the standard ubuntu, not kubuntu or some other variation. You can change this by editing the file /etc/inittab. After you do startx open a terminal from the menu and type sudo gedit /etc/initab After you type your password in this should bring up a file in a text editor, that's what gedit is. One of the first lines will say #default run level. Just below this line will be id:number:initdefault: , the number specifies the level when you start. It seems like you're in 2, you should change the number to 5. Save the file and then close it. You should go straight to a graphical login screen next time you start your computer.

I think there's a way to do this from the administration menu also, but I don't remember how, I don't use gnome for my desktop anymore. I do know that there's a way to set it to automatically log you in from one of the options in this menu, which seems more like what you want anyway.

I'm not certain about setting startup programs, but I think it's something like in system->preferences->sessions. I think there was a tab for startup programs, and then specify the command to run on startup. For instance if I wanted thunderbird to start I would use the command mozilla-thunderbird. This will only start them when you log on with gnome, if you want something to run as soon as the computer starts it's a bit more complicated and I haven't really taken the time to figure that out yet.

timmeke 01-06-2006 08:52 AM

Actually, it depends on what kind of startup programs you want.
Since you seem to know a little about Windows/DOS, I'll give you a few possibilities:
Windows
background services
Configure them via Config Panel - Administrative Tools - Services

Linux
Stored in /etc/init.d, symlinks in /etc/rc.d/...; /etc/rc.local may also be similar
Started when you enter certain runlevels like 3, 4 and 5 (after normal boots).
Check out:
man init
man chkconfig
man service
You need to be "root" to run chkconfig and service programs.
This mechanism should only be used for daemon programs/network services. So be careful what you put
in /etc/init.d.

Win:
autoexec.bat
Is actually only executed if you start windows. A different autoexec is started when you boot to Dos.
Lin:
KDE and Gnome startup files. Where you put these, depends on your Linux distro. Search this forum and Google, I'd say.

Win:
startup programs for all users (ie in "docs&settings\all users\startup" or something)
Lin:
put programs in /etc/profile (executed at each login) or /etc/bashrc (executed at login to a bash shell)

Win:
startup programs per user (ie in "docs&settings\your_user\startup" or something - also in your start menu under "startup")
Lin:
In user's home directory, put the commands in the files .profile (applies to all shells) or .bashrc (for bash
shells only). Similarly, you can also have .cshrc for csh shell, .kshrc for ksh shell, etc.

The comparisons are somewhat sketchy at best, but you get the idea: Linux can do anything you do in Windows and even more!

Komakino 01-06-2006 05:08 PM

The file you're looking for is rc.local which is somewhere in /etc/rc.d(x) or possible /etc/init.d
I'd like to be more specific but I use slackware which has far easier startup scripts in far more sensible places!

ursinus 01-07-2006 07:52 AM

Quote:

Originally Posted by mcmillan
Normally by default ubuntu should take you to the graphical interface, but it seems like isn't working for some reason. I'm giving directions assuming you're using the standard ubuntu, not kubuntu or some other variation. You can change this by editing the file /etc/inittab. After you do startx open a terminal from the menu and type sudo gedit /etc/initab After you type your password in this should bring up a file in a text editor, that's what gedit is. One of the first lines will say #default run level. Just below this line will be id:number:initdefault: , the number specifies the level when you start. It seems like you're in 2, you should change the number to 5. Save the file and then close it. You should go straight to a graphical login screen next time you start your computer.

I changed the default run level from 2 to 5 but it seems to have no effect. The change is saved allright because while the computer is running the startup it indicates that the run level is 5, not 2. And yes, I'm using the regular version of Ubuntu.

Flesym 01-07-2006 08:30 AM

What happens if you run 'gdm' (located in '/usr/sbin')?


All times are GMT -5. The time now is 02:28 PM.