102-400 · Question #102
Which file used by XDM specifies the default wallpaper?
The correct answer is A. /etc/X11/xdm/Xsetup. See the full explanation below for the reasoning.
Question
Options
- A/etc/X11/xdm/Xsetup
- B/etc/X11/xdm.conf
- C/etc/X11/xdm/Defaults
- D/etc/X11/defaults.conf
How the community answered
(51 responses)- A78% (40)
- B12% (6)
- C4% (2)
- D6% (3)
Community Discussion
4The answer is A, /etc/X11/xdm/Xsetup. This is a shell script that XDM executes as root right before the login screen appears, which makes it the correct place to set display-level things like the background wallpaper using xsetroot or a similar command. The exam loves to test this because the name "Xsetup" sounds generic, but its specific role in the pre-login display setup is exactly what makes it the wallpaper hook. The other options are either invented paths or config files that handle different concerns, so if you see a question about anything that needs to run visually before the login dialog shows up, Xsetup is your answer every time.
The answer is A, /etc/X11/xdm/Xsetup. That file is a shell script that XDM runs as root before the login box appears, which is exactly where you drop your xsetroot or feh command to set the wallpaper.
Going with B on this one, and here is my reasoning. XDM reads its core runtime configuration from xdm.conf, and that file is where you set global display defaults, which absolutely covers visual presentation defaults like the wallpaper. The word "Defaults" in option C sounds tempting but that file handles resource settings for the chooser and greeter widgets, not the wallpaper path itself. Xsetup in option A is a shell script that runs before the login box appears, so it can call xsetroot or feh, but XDM does not read it to "specify" a wallpaper the way a config file does. The phrasing of the question, "specifies the default wallpaper," points me toward a declarative config file, and xdm.conf is the central config for XDM, so B is my pick.
Devraj, the cert is looking for A because Xsetup is literally the script XDM executes to set up the display before the greeter loads, and calling xsetroot or feh inside it is the actual documented mechanism for specifying that default wallpaper. xdm.conf is not a standard XDM file name, and no XDM config file accepts a wallpaper directive the way you are describing.