Koozali.org: home of the SME Server

Accidentelly removed all action scripts

Offline cactus

  • *
  • 4,880
  • +3/-0
    • http://www.snetram.nl
Accidentelly removed all action scripts
« on: March 05, 2006, 09:40:32 PM »
I just accidentally removed all of the action scripts from the server (while I thought I was cleaning my RPM build tree, stupid I know :-) )

Does someone know a way of undeleting them or restoring the scripts or is the only option to reinstall the server?

Hoefully someone can help me... thanks!
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Offline gordonr

  • *
  • 646
  • +0/-0
    • http://www.smeserver.com.au/
Re: Accidentelly removed all action scripts
« Reply #1 on: March 06, 2006, 02:02:19 AM »
Quote from: "cactus"
I just accidentally removed all of the action scripts from the server (while I thought I was cleaning my RPM build tree, stupid I know :-) )

What were you doing building RPMs as root? There is no need and it's dangerous, as you have found. If an RPM SPEC file requires root to build, fix it so that it doesn't and send the patches to the author.
Quote from: "cactus"

Does someone know a way of undeleting them or restoring the scripts or is the only option to reinstall the server?

Hoefully someone can help me... thanks!


In the Australian vernacular, your username is rather appropriate to the situation :-)

The simplest way will be a reinstall. If you have another box, you could do an install there and copy the actions directory across. I would then peform a backup, fresh install and restore to ensure that all is as it should be.

Another option is a forced upgrade of all of the e-smith-* and smeserver-* packages. I would again do a backup/reinstall/restore to ensure that you haven't missed anything.
............

Offline cactus

  • *
  • 4,880
  • +3/-0
    • http://www.snetram.nl
Re: Accidentelly removed all action scripts
« Reply #2 on: March 06, 2006, 10:00:18 AM »
Quote from: "gordonr"
What were you doing building RPMs as root? There is no need and it's dangerous, as you have found. If an RPM SPEC file requires root to build, fix it so that it doesn't and send the patches to the author.

I was not building as root (I know this is dangerous) but had another ssh session opened as root user (to do some quick changes I still had to do) and accidentally entered the rm -rf command in the wrong window.
Quote from: "gordonr"
In the Australian vernacular, your username is rather appropriate to the situation :-)

LOL, this name is for a reason... but not this one. It had more to do with the way I wore my hair at the time I registered, and perhaps with my charachter sometimes :-).
Quote from: "gordonr"
The simplest way will be a reinstall. If you have another box, you could do an install there and copy the actions directory across. I would then peform a backup, fresh install and restore to ensure that all is as it should be.

Another option is a forced upgrade of all of the e-smith-* and smeserver-* packages. I would again do a backup/reinstall/restore to ensure that you haven't missed anything.

I decided to do a scratch install and restore my backup (yes, one learns from previous mistakes so I made backups) and discovered a possible bug with the backup of mysql databases as filed in the bugzilla system (@gordonr: But you already knew this).
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)