Jump to content

Script to Repair Installation


Steve Scrimpshire
 Share

Recommended Posts

  • Replies 40
  • Created
  • Last Reply

Top Posters In This Topic

Steve,I already got my urpmi sources, but found when I tried your script Example "! /bin/bash" & rpmfix to start things off that I got no response ,so I thought one of these 2 posts might of led to more examples , Im still a linux novice trying to learn but have a little trouble understanding scripting but want to give it a go, I have come accross some tutorials in somePC mags I have and will see if they can get me going as well? I havnt read your tutorial right through yet so maybe I have done something wrong , Should typing ! /bin/bash or rpmfind give me some results or do I have something missing? Thanks

Link to comment
Share on other sites

Ahhh...I see the problem. What i posted is a script not commands you run from a terminal. Copy and paste the entire code sample into a file and save it, making sure that #!/bin/bash is on the very top line. You can name it whatever yo want, like repairinstall. Then type this command:

chmod +x repairinstall

then as root:

./repairinstall

 

If you are already running this as a script, make sure all the lines that have # in the beginning, keep them.

Edited by Steve Scrimpshire
Link to comment
Share on other sites

Hi Steve,

 

What you said earlier about XFree packages (they seem to need being reinstalled everytime) is valid for my glibc-devel and kernel-source packages as well. So, I changed a line in your script:

if [[ $name != XFree* ]]

Is now:

if [[ $name != XFree* && $name != glibc-devel* && $name != kernel-source* ]]

Now they don't bother me anymore... :afro:

 

Just thought I'd let you know about it.

 

Cheers

Link to comment
Share on other sites

  • 2 months later...

In Nautilus (GNOME), it would be:

Right-click the file -> Properties -> Permissions -> Check "Executable" checkboxes

 

Or, in a terminal, type in:

chmod a+x rpmfix

Assuming you named the script "rpmfix". Otherwise, just replace that with whatever you named it.

 

Cheers,

Link to comment
Share on other sites

Hmmm... no argument to your request sounds like you aren't missing any files.

Can you attach your missing_files.list to a post here? You'll have to rename it to missing_files.txt to get it to attach. It'll be in the same directory you run the script from.

Link to comment
Share on other sites

I meant the file called missing_files.list that the script creates in the directory you run the script from. If the file does not exist, it means either:

(a) You do not have write permissions in the directory you run the script from

(b) None of your rpms are missing any files, which is highly doubtful

Edited by Steve Scrimpshire
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...