LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Would anyone know... (https://www.linuxquestions.org/questions/linux-newbie-8/would-anyone-know-926816/)

bnbntx 01-31-2012 09:00 PM

Would anyone know...
 
..where the main gdm3 file in housed. Here's my scenario. Very new to this OS and only play around w it when time allows. Anyway, about 9 mo ago I wanted to stop X from running at boot and I changed a config file SOMEWHERE to stop it from happening. It had something to do with GDM3 and I think I commented it out of SOME run file. Problem is now I can't remember where the file is that I changed. Regarding GDM3 this and that's all I'm finding are exe files. I typically rename any file I change to ~.default b4 making edits. I've tried doing a search over the entire FS but think my command has many syntax errors. Can anyone shed some light.

aikiwav 01-31-2012 09:36 PM

You mentioned that you may have errors in your command. Here's what I would have tried:

as root (for access to all directories)
Code:

find / -name *gdm3*
If it's a long list, pipe it into the less command:
Code:

find / -name *gdm3* | less
As far as stopping X running at boot, it may depend on your distribution, but here's a link to a Slackware solution; yours may be similar.
https://www.linux.com/community/blog...l-linux/421567

frankbell 01-31-2012 09:48 PM

Depending on your distro, it was most likely the default runlevel setting in /etc/inittab if you disabled the GDM by changing a configuration file.

What distro are you using, anyhow?

bnbntx 01-31-2012 09:56 PM

I finally remembered how to use "locate" and found the file I originally updated. Problem is I'm finding it hard to articulate what I think I did when editing the file. Here's the file in question:

lrwxrwxrwx 1 root root 14 Aug 24 09:44 S05gdm3_dav -> ../init.d/gdm3

I have not used unix commands for years and recently got back into it. That said I know enough to be dangerous at times. That said.. using what I found didn't I create a symbolic link or a redirect to the original file. I'm afraid of simply deleting the _dav file because won't that delete the .../init.d/gdm3 file? What should I do? Thanks for your reply BTW.

aikiwav 01-31-2012 09:59 PM

You may want to wait for a more seasoned linux user to be sure, but I believe that deleting the symbolic link would not delete what it points to. I think of symbolic links like a shortcut icon in Windows.

That being said, make sure that symbolic link isn't needed. I had to create a symbolic link for Firefox to find my java installation, so if I had deleted that link and stopped there, Firefox would have been (partially) broken.

catkin 01-31-2012 10:07 PM

Removing a symbolic link does not remove the link target.

bnbntx 01-31-2012 10:07 PM

I'm currently running the newest version on Debian. As far as the exact version.. Well I don't know that command either...lol
Prior to posting my Q I did research or rather backtrack what I may have done for roughly 2hrs. The inittab option didn't work back in the day b/c I wanted to be able to "startx" at will or when it was needed. For the most part how I made the original edit to the gdm3 file was probably done so by NOT fully understanding exactly what I was doing and giving it a shot. I achieved MY desired result and moved on. Oh, did I mention I know enough to be dangerous?

bnbntx 01-31-2012 10:27 PM

Okay thanks all. Deleted and now rebooting..

bnbntx 01-31-2012 10:37 PM

Well CRAP!! That didn't work like expected. After reboot it never started X but did what I original made the edit(s) for some time ago. It simply drops me at a "username" prompt. I'm not understanding something here. Anyone?? I'd rather not have to reinstall this OS even know this is only a hobby srv.

aikiwav 01-31-2012 10:40 PM

I'm not sure what result you're hoping for. Could you try to restate what you're wanting to see?

bnbntx 01-31-2012 10:56 PM

Sure.. It might help to describe my original intentional. Hmkay.. Understanding I know very little, my original mindset was to build a headless srv that would reboot, auto login etc.. With this in mind I found myself on a forum (prob this one) reading through diff ideas on how to achieve this. Step 1 was to stop x from running. I achieved this by creating this S-link which probably ran a file with some type of entry removed that started the gui. Fast forward to a cpl days ago and I'm back. Found the S-link, now removed and upon booting srv it still doesn't start X. I'm trying to reverse my handy work b/c I now have a solution to stopping X from running while still achieving the original idea.

aikiwav 01-31-2012 11:11 PM

It sounds to me like you want X to start when booting (previously you stopped X from booting as part of a server setup).

If you haven't checked already, follow frankbell's advice and look to see if you have a /etc/inittab file. In mine, the relevant section looks like this:

Code:

# These are the default runlevels in Slackware:
#  0 = halt
#  1 = single user mode
#  2 = unused (but configured the same as runlevel 3)
#  3 = multiuser mode (default Slackware runlevel)
#  4 = X11 with KDM/GDM/XDM (session managers)
#  5 = unused (but configured the same as runlevel 3)
#  6 = reboot

# Default runlevel. (Do not set to 0 or 6)
id:3:initdefault:

That's the line that determines where the booting process goes (command line vs. GUI). Perhaps it's set to the wrong number; the above example would boot to command line, but if I changed the last line to
Code:

id:4:initdefault:
it should boot directly to my GUI.

bnbntx 01-31-2012 11:30 PM

Here's my inittab file:

# /etc/inittab: init(8) configuration.
# $Id: inittab,v 1.91 2002/01/25 13:35:21 miquels Exp $

# The default runlevel.
id:2:initdefault:

# Boot-time system configuration/initialization script.
# This is run first except when booting in emergency (-b) mode.
si::sysinit:/etc/init.d/rcS

# What to do in single-user mode.
~~:S:wait:/sbin/sulogin

# /etc/init.d executes the S and K scripts upon change
# of runlevel.
#
# Runlevel 0 is halt.
# Runlevel 1 is single-user.
# Runlevels 2-5 are multi-user.
# Runlevel 6 is reboot.

l0:0:wait:/etc/init.d/rc 0
l1:1:wait:/etc/init.d/rc 1
l2:2:wait:/etc/init.d/rc 2
l3:3:wait:/etc/init.d/rc 3
l4:4:wait:/etc/init.d/rc 4
l5:5:wait:/etc/init.d/rc 5
l6:6:wait:/etc/init.d/rc 6
# Normally not reached, but fallthrough in case of emergency.
z6:6:respawn:/sbin/sulogin

# What to do when CTRL-ALT-DEL is pressed.
ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now

# Action on special keypress (ALT-UpArrow).
#kb::kbrequest:/bin/echo "Keyboard Request--edit /etc/inittab to let this work."

# What to do when the power fails/returns.
pf::powerwait:/etc/init.d/powerfail start
pn::powerfailnow:/etc/init.d/powerfail now
po::powerokwait:/etc/init.d/powerfail stop

# /sbin/getty invocations for the runlevels.
#
# The "id" field MUST be the same as the last
# characters of the device (after "tty").
#
# Format:
# <id>:<runlevels>:<action>:<process>
#
# Note that on most Debian systems tty7 is used by the X Window System,
# so if you want to add more getty's go ahead but skip tty7 if you run X.
#
1:2345:respawn:/sbin/getty 38400 tty1
2:23:respawn:/sbin/getty 38400 tty2
3:23:respawn:/sbin/getty 38400 tty3
4:23:respawn:/sbin/getty 38400 tty4
5:23:respawn:/sbin/getty 38400 tty5
6:23:respawn:/sbin/getty 38400 tty6

# Example how to put a getty on a serial line (for a terminal)
#
#T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100
#T1:23:respawn:/sbin/getty -L ttyS1 9600 vt100

# Example how to put a getty on a modem line.
#
#T3:23:respawn:/sbin/mgetty -x0 -s 57600 ttyS3

aikiwav 01-31-2012 11:41 PM

Huh. So none of your runlevel options boot you into gdm. Would you be willing to post the contents of /etc/init.d/rc4 ? That's what boots me into gdm/kde, so maybe if I compare yours to mine I can offer a suggestion.

bnbntx 01-31-2012 11:46 PM

Just found this entry and wanted to ask it others could confirm.


I found this in my /etc/init.d/gdm3

# To start gdm even if it is not the default display manager, change
# HEED_DEFAULT_DISPLAY_MANAGER to "false."
HEED_DEFAULT_DISPLAY_MANAGER=true
DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager

Could this be what I changed? Can anyone that starts x automatically look at theirs and compare?


All times are GMT -5. The time now is 06:31 AM.