1

I installed Google Desktop for Linux and want to prevent it from running without necessarily deleting all its files. I managed to find and disable the file in /etc/cron.hourly, but gdl_box is still being launched by process 1:

1  5199  5199  5199 ?           -1 Ss   32074   0:01 /opt/google/desktop/bin/gdl_box

I've grepped for gdl in every file under /etc and have turned up no suspects. There doesn't seem to be anything in /etc/init.d or in the /etc/rc*.d directories. How can I find and slay this evil daemon? More exactly, how can I find out what is causing it to be spawned and prevent it from ever spawning in the first place?

I have killed the gdl_box over and over, but without a reboot or an X restart, something in the system keeps respawning it. I would like to find out what and stop it.


EDIT

OK, eventually I replaced gdl_box with a binary that ran ps afwj so I could tell who launched it before it got adopted by init. Imagine my embarrassment when I discovered it was launched from my .profile. I still would love to know a better way to have discovered this, but I've accepted the answer which pointed out the adoption by init (thanks Thomas) which at least stopped me looking under the wrong lamppost.

Norman Ramsey
  • 645
  • 2
  • 10
  • 24

4 Answers4

2

I assume the first column in the ps output you show is the parent pid (PPID). If so, it's probably not spawned by init (if that is what led you to believe that), but in normal unix daemon-style it double-forks which causes it to get a parent pid of 1. It was a orphan and init adopted it.

How can you find and slay it? Uh... it's right there, what aren't you finding?

Thomas
  • 1,446
  • 11
  • 16
  • Sorry -- I've edited question to show I want to know how to prevent the daemon from spawning. Killing it does no good is something else keeps spawning it. – Norman Ramsey Jun 17 '09 at 20:12
1

Google desktop is started from (at least on my RHEL5 system):

/etc/xdg/autostart/gdl_box.desktop

TCampbell
  • 2,014
  • 14
  • 14
0

Some versions of ps support a --forest or f flag to show the tree of relationships between processes. If your version doesn't have that, check for pstree, a stand-alone package to do the same thing. It can help in cases like this.

Telemachus
  • 561
  • 2
  • 11
0

What about running

find /var/spool/cron -type f | xargs grep gdl

or maybe there is a script that is loading gdl_box, but the script is not actually called gdl itself which is why a grep isn't turning anything up.

resonator
  • 281
  • 1
  • 10