First time Linux user needs advice

General discussion about Celestia that doesn't fit into other forums.
Topic author
jrobert
Posts: 95
Joined: 09.08.2002
With us: 22 years 1 month
Location: California, USA
Contact:

First time Linux user needs advice

Post #1by jrobert » 12.06.2003, 00:01

I just downloaded Mandrake Linux 9.1 and would like to set up celestia for it. I've never used linux before and from what I see thus far, it looks pretty cool! Any help would be appriciated :wink:

adyga
Posts: 29
Joined: 03.06.2003
With us: 21 years 4 months
Contact:

Post #2by adyga » 12.06.2003, 01:07

hi,
very easy man:
http://www.celestiaproject.net/celestia/download.html
download the 2 rpms for mandrake, then install from packageorganizer or console:
rpm -Uvh .......
and before you run celestia you need the accelerated graphics drivers for your graphics card to run Celestia !!
u can then run celestia directly typing celestia in console
have fun :D
Rig1:
Athlon XP 2000+
MSI6172 + 768 Kingston DDR
GF FX5200 128MB
Win XP Professional + SP2
Rig2:
Duron 1000
ECS K7S5A + 768 Kingston DDR400
GF2 MX400
Win XP Pro SP2
Laptop:
Fujitsu Siemens Amilo M7400
Win XP Pro SP2

Christophe
Developer
Posts: 944
Joined: 18.07.2002
With us: 22 years 2 months
Location: Lyon (France)

Post #3by Christophe » 12.06.2003, 08:19

I'll simply add that Celestia is also available from the menu (the K menu in KDE or the Foot menu in Gnome), it's in Applications -> Sciences -> Astronomy.
Christophe

Topic author
jrobert
Posts: 95
Joined: 09.08.2002
With us: 22 years 1 month
Location: California, USA
Contact:

Post #4by jrobert » 12.06.2003, 08:26

Okay, I installed both the base and texture rpms for mandrake. I then went to Nvidia to get the latest linux drivers. On their website, it indicated that I may need the XFree86 distribution. After installing the Nvidia and XFree86 distributions, I was told by the Nvidia driver installation that editing the XF86Config file was necessary. This is where things get fuzzy for me. On a whim, I tried to run Celestia and it runs but alas without loading the GL library. So when I close it, I get the KDE Crash Handler which states the Celestia has crashed causing the signal 11 (SIGSEGV). Basically, I'm unclear on the reconfiguring of the XF86Config file. :?

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #5by jamarsa » 12.06.2003, 08:50

I think he matter is that you have replaced the OpenGL engine without changing the driver, so you are unable to do OpenGL rendering, and that's why celestia crashes.

These are the instructions of how to change the driver used. Be aware that it could happen that you would be unable to restart in graphics mode after doing this, so make a copy of the file before changing it. If happen to be in this situation, please tell us to give you the commands to restore it.

The editing part I'm telling you from memory, so wait a little before trying to give me time for updates (15 minutes at most).

First update. replaced xedit with emacs, and added a pair of notes

You just have to edit the /etc/X11/XF86Config-4 file and replace the line:


Driver "nv"

with:

Driver "nvidia"

How to do editing in Linux. Note: You *must* be root user to do this (It's the Adminstrator for Unix). I assume you have not idea of the use of the "vi", which is the editor I prefer.. So you can use emacs:
(A little update, I found no xedit in Mandrake, so I changed it to emacs instead)

Press Alt-<F2>, appears "run command". Type:

emacs <Return>

Do a File - Open... select the /etc/X11 folder, and open "XF86Config-4". Do the changes, and save it (if you like, you can save a copy before editing). Close the window, and do a CTRL-ALT-Backspace (this key combination kills the X Server, I'm not sure logging out would be enough).

Note: the case of letters have significance in linux, so you must type emacs, not EMACS.
Last edited by jamarsa on 12.06.2003, 09:32, edited 4 times in total.

Christophe
Developer
Posts: 944
Joined: 18.07.2002
With us: 22 years 2 months
Location: Lyon (France)

Post #6by Christophe » 12.06.2003, 09:04

jamarsa wrote:Do a File - Open... select the /etc/X11 folder, and open "XF86Config".


Small typo here, it's XF86Config-4, not XF86Config. Both files exist but it's XF86Config-4 that you need to edit.
Christophe

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #7by jamarsa » 12.06.2003, 09:29

Thanks Christophe!! Yes, It was just a typo. There were other mistakes, however, I have replaced. Please review me if you like, I don't work in KDE nor emacs too often... :roll:

Topic author
jrobert
Posts: 95
Joined: 09.08.2002
With us: 22 years 1 month
Location: California, USA
Contact:

Post #8by jrobert » 12.06.2003, 22:17

Okay, here's a rundown of what I did since my last post to this thread....

I found which XF86Config file linux is using (it's using XF86Config-4). I edited the Driver "nv" to read Driver "nvidia" and hit CTRL-ALT-BKSP... The X server then failed to load. so I changed the file back to its original using emacs (which btw I now understand why no one likes that utility)

I attempted to reinstall the XFree86 distribution and still no luck. So I thought maybe there's something corrupt in the linux distribution since being one of the graphical interface files wouldn't copy from the cd on the initial install of mandrake. This prompted me to check the md5sum on the downloaded distributions. They matched, and so I reburned the second cd, and completely reinstalled mandrake 9.1. I then found out that mandrake comes with XFree86 so there wasn't any need for me to get it from their website. I then installed celestia and it worked however very slow. So I installed the nvidia linux driver according to its instructions and ended right back up at square-one.

Now when I run celestia, the same thing occurs as before, no OpenGL window appears and when I close it out, it crashes. When I modify the XF86Config-4 file so that Drivers "nv" is now Drivers "nvidia", X server then fails to load.

I am now definately lost as what to try next. :?

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #9by jamarsa » 12.06.2003, 22:43

The next step may be to analyze what went bad in XFree86. There is a logfile called "XFree86.0.log", placed in /var/log folder. Please send me that file to jamarsa@yahoo.es or, if the size is suitable, post it in the forum. Linux and XFree are very verbose at the things they do, to help track problems as yours.

If you have trouble sending the file from linux, you can 'copy and paste' onto a DOS formatted floppy, or do a 'mcopy /var/log/Xfree86.0.log a:' at console.

Note: You need to grab the file before restoring XFree86-4 to its previous state. If you restart the graphics mode with the old "nv" driver, the log will be overwritten. So is better to make a previous copy into another name. I assume that, being able to restore the XF86Config-4 with emacs, you can make a copy with the "save as..." option while editing this log. You can use also the command mcopy as referred up to copy to a floppy, or do a "cp <origin> <destination>" if you wish.

And I don't blame emacs, It's just a matter of tastes, and I am too used to the "vi" editor and find it too powerful to bother to make a change. I use "vi" in Windows environments too, because I can develop code and reformat text almost as fast as I think of it. But emacs is very powerful too with it's macros approach.

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #10by jamarsa » 12.06.2003, 23:28

After re-reading the driver documentation from nVidia, I just remembered one important thing. One of the RPMS is the kernel module. Perhaps your system is forgetting to load it. Do a:

/sbin/lsmod | grep nvidia

if you don't see a line saying "nvidia ...." then you can try to use it:

/sbin/modprobe nvidia

and repeat the first command. If you still don't see it, post us the output of the second command. I had to do a rebuild from the source RPM to be able to use the kernel module (well, if fact I didn't try the binary first, I knew in advance I would have to :wink: ). I think this could be your most likely gremlin (goblin?).

Topic author
jrobert
Posts: 95
Joined: 09.08.2002
With us: 22 years 1 month
Location: California, USA
Contact:

Post #11by jrobert » 13.06.2003, 01:58

I am now the proud owner of a system with a properly configured linux nvidia driver!! :D The modprobe and lsmod did the trick! This thread should be invaluable for other linux newbies who may want to try Celestia for linux. :D

I have just one more question: When I reboot the machine, it goes back to using the older driver. How do I do a script that'll do the modprobe and lsmod automatically when linux starts?

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #12by jamarsa » 13.06.2003, 07:01

jrobert wrote:

I am now the proud owner of a system with a properly configured linux nvidia driver!!

Congratulations!! That was a direct hit, and a lucky one, you know :wink:

jrobert wrote:
I have just one more question: When I reboot the machine, it goes back to using the older driver. How do I do a script that'll do the modprobe and lsmod automatically when linux starts?


That's a simple matter!! Just let the system load the module whenever it needs it. Only add this line to the file /etc/modules.conf :

alias char-major-195 nvidia

This way, when it tries to open the device (marked as the 195 in the kernel list), it loads the module automagically!! :lol:

Did your celestia work properly in Linux? There were other minor things to check to ensure a healthy OpenGL environment...

Christophe
Developer
Posts: 944
Joined: 18.07.2002
With us: 22 years 2 months
Location: Lyon (France)

Post #13by Christophe » 13.06.2003, 08:10

I must say I'm impressed you managed to get it to work being a total linux newbee.

By the way XFree86 is a free (open source) implementation of the X Windows system which is the main (if not ony one) windowing system on Unix. It is of course part of all Linux distributions, without it you would only have a text console.

If you want to learn more about your new linux system I would recommend you to read the Mandrake documentation. The Linux Documentation Project is also a good place to find guides and how-tos.
Christophe

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #14by jamarsa » 13.06.2003, 08:24

Christophe wrote:

I must say I'm impressed you managed to get it to work being a total linux newbee.


I'm impressed too!! such easiness at being able to restore the old XFree86 config is to be taken into account!! I had to dramatically raise my explanation level to keep pace with jrobert improvement!! :lol:

Topic author
jrobert
Posts: 95
Joined: 09.08.2002
With us: 22 years 1 month
Location: California, USA
Contact:

Post #15by jrobert » 13.06.2003, 13:25

the /etc/modules.conf already has an entry for char-major-195 nvidia. During the boot up process, it appears that it trys to load the new driver but fails. So lets go with what works... somewhere, somehow there must be a way to add lsmod and modprobe events to something like the DOS "autoexec.bat" file if you will.

As for all the help you ppl have provided, I am eternally grateful. In my profession, I use an Silicon Graphics machine which uses Irix. Irix is also unix in nature but everything is tightly maintained by our support staff. So knowing how to get around in unix isn't really a requirement of my job. I do however, know some basic unix commands for getting around without a GUI. I'm going to say the breakthru came when you told me about emacs text editor. Even though I don't like using it, it's the only editor I've been using when the GUI wouldn't load up.

Christophe
Developer
Posts: 944
Joined: 18.07.2002
With us: 22 years 2 months
Location: Lyon (France)

Post #16by Christophe » 13.06.2003, 13:37

jrobert wrote:the /etc/modules.conf already has an entry for char-major-195 nvidia. During the boot up process, it appears that it trys to load the new driver but fails. So lets go with what works... somewhere, somehow there must be a way to add lsmod and modprobe events to something like the DOS "autoexec.bat" file if you will.

You can add it at the end of /etc/rc.d/rc.local

jrobert wrote:I'm going to say the breakthru came when you told me about emacs text editor. Even though I don't like using it, it's the only editor I've been using when the GUI wouldn't load up.


You're right, vi is much better ;-)
Christophe

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #17by jamarsa » 13.06.2003, 14:29

jrobert wrote:

the /etc/modules.conf already has an entry for char-major-195 nvidia. During the boot up process, it appears that it trys to load the new driver but fails.

strange... Did you got the /dev/nvidia* files created? to find it, do a:

ls -l /dev/nvidia*

Also you could try the approach made by adyga in his recent sticky FAQ (place it in /etc/modutils/aliases -if you have it; I don't-). As a last resort, do as Christophe says: place the command in /etc/rc.d/rc.local; its one of the several 'autoexec.bat' executed at the end of boot time. Note: only the modprobe command is necessary; lsmod only lists what is already there.

Christophe wrote:

You're right, vi is much better ;-)


Right!! Everything done without all these combined ALT/CTRL+key of other editors!! You can almost work with one finger!! The ultimate interface!! :lol:

Topic author
jrobert
Posts: 95
Joined: 09.08.2002
With us: 22 years 1 month
Location: California, USA
Contact:

Post #18by jrobert » 14.06.2003, 23:30

Okay, doing a ls -l /dev/nvidia* before doing a modprobe nvidia yields this:
ls: /dev/nvidia*: No such file or directory

doing a modprobe nvidia yields this:
Warning: loading /lib/modules/2.4.21-0.13mdk/kernel/drivers/video/nvidia.o will taint the kernel: non-GPL license - NVIDIA
See http://www.tux.org/lkml/#export-tainted for information about tainted modules
Module nvidia loaded, with warnings

doing a ls -l /dev/nvidia* AFTER modprobe yields this:
crw------- 1 root root 195, 0 Dec 31 1969 /dev/nvidia0
crw------- 1 root root 195, 255 Dec 31 1969 /dev/nvidiactl

I don't have the /etc/modutils/aliases directory and placing the modprobe nvidia event in the rc.local file didn't do the trick either. :?

jamarsa
Posts: 326
Joined: 31.03.2003
With us: 21 years 6 months
Location: San Sebastian (Spain)

Post #19by jamarsa » 15.06.2003, 00:10

You may try one of these workarounds:

a) Hmm, I didn't say you because I was following the manual, but, instead of the char-major-135 issue, I have this line in /etc/modules.conf (I don't remember why :? ) :

alias /dev/nvidia* nvidia

Note: the asterisk (*) is exactly as shown, without space before.

b) On the other way, perhaps placing the modprobe in /etc/rc.d/rc.local wasn't a good idea, because I now recall Mandrake loads the graphics interface before executing this file.

Try this different approach. Place the line:

nvidia

in the file /etc/modules. This file contains the name of the modules that must be loaded at boot time. Next time it boots, it checks first this file and do a modprobe of each line you put there.

bb) Another way would be to create a rc file that would execute prior to the graphics launch:

emacs /etc/rc.d/rc5.d/S76nvidia

(place the line /sbin/modprobe nvidia in this file)

save, and enter this command:

chmod +x /etc/rc.d/rc5.d/S76nvidia


and reboot the system.

PS: going to sleep now, will be back at six hours from now.

Topic author
jrobert
Posts: 95
Joined: 09.08.2002
With us: 22 years 1 month
Location: California, USA
Contact:

Post #20by jrobert » 15.06.2003, 00:28

jamarsa wrote:Place the line:

nvidia

in the file /etc/modules. This file contains the name of the modules that must be loaded at boot time. Next time it boots, it checks first this file and do a modprobe of each line you put there.

That worked! :D Thanks!


Return to “Celestia Users”