Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I was using Ubuntu happily for some months (almost fully updated, latest AMD driver and everything). About a week ago I started trying to install some games that I bought on Humble Bundle that I downloaded at home and other PCs (my internet is a piece of crap, so it's easier by Torrent), and some of them were .deb files.

When I tried to install those, some would try to install and then go back, like nothing happened (probably because of an internal error), or asked for dependencies that I couldn't find. Because of those problems, I tried to install the same packages using the Terminal (using sudo dpkg -i <package name>), but after a while a red balloon icon appeared on the Menu Bar with an error on a file that contained repositories (don't remember the exact error, sorry. But I think it was that it was invalid and it couldn't write it).

I left it to fix later, but after a while the Software Center started giving broken package error and asked to repair it, so I opened the Terminal and did apt-get install -f, like I did when that happened before. It asked me to download 888 Kb of packages and I allowed it, but then, shortly after, it started removing everything on the system on its on. It uninstalled the interface, the network driver, a lot of programs, and so on.

When I noticed it, I quickly closed it but it was too late. The Network Connection menu was gone (and probably the driver), so I couldn't use the internet. Seeing that there was nothing I could do on my own, I rebooted to see if it was temporary, but now the system boots without a graphical interface (it only shows tty).

I have a 3G internet (slow as hell), and I don't know how to connect it using only the terminal, so it is a lot more difficult to fix it. So, is it possible to fix it without reinstalling (PLEEEASE, DON'T MAKE ME REINSTALL THAT WITH THIS CRAPPY CONNECTION)?, and I have the Live USB here if necessary.

Oh, and I forgot to give important information. I am using Ubuntu 12.10 AMDx64, installed on a 101GB ext4 partition. There were only 58MB (approximately) of updates waiting to be done (so it was updated, mostly).

share|improve this question
2  
Your question is very difficult to read. You will get more and better answers if you write it so that it can be read more easily. –  guntbert Apr 16 '13 at 19:32
1  
Why did it do this? We can't tell without the errors it gave you, but from the sound of it you completely mutilated the packaging system.. broken dependencies can be a big problem. –  Seth Apr 16 '13 at 19:37
1  
You can preserve some of the previously installed packages and use them for re-installation by backing up the /var/apt/archives. It contains .deb of the packages which were installed by apt. –  green7 Apr 16 '13 at 19:54
    
Humm... that could work too... but it would backup the updates I did and the video driver? What about Steam and its games? If it backups ALL my programs and updates, then reinstalling it would be a good option. Just need a way to read the ext4 partition on Windows or copy it using the terminal. –  White Apr 16 '13 at 21:10
add comment

1 Answer

Probably you have installed some deb which conflicted with some package that probably was required for some of the applications you mentioned, so they were removed.

If you are using 12.04, I some time ago have seen a bug that may be related to what happened to you (apt-get removed some packages when asked to install 32bit libs, if i'm not wrong).

Either way you should be able to recover, but you will need an internet connection and you may need to download some packages.

To connect your 3G device see if this helps. You may also need to edit /etc/resolv.conf with your DNS information. Also there is a small tool called sakis3g that may help you.

After you are connected to the internet, try

sudo apt-get install ubuntu-desktop

This should install everything that is in a default Ubuntu installation. Note that probably you will need to uninstall whatever caused the conflict.

If it doesn't work you can use dpkg --get-selections to get a listing of the installed/removed packages, and from there install them manually (ie, one by one).


Tip: next time you need to check whatever apt-get will do, add --dry-run to the command: it will only simulate the execution, and will not modify the system. Example:

$ sudo apt-get remove tasksel --dry-run
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages will be REMOVED:
  tasksel tasksel-data
0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.
Remv tasksel [2.88ubuntu9] [tasksel-data:amd64 ]   <-- tasksel would be removed.
Remv tasksel-data [2.88ubuntu9]                    <-- tasksel-data would be removed.
share|improve this answer
    
Thanks for the nice answer, despite of the lack of info on my post. I'll try what you said, I'll see if my neighbor lets me plug my computer on his cable internet to fix it, if not, I'll see the links you gave me. Thanks for everyone who answered, also. –  White Apr 16 '13 at 20:02
    
Oh, but I remebered that after the incident, I couldn't load any internet pages, and the Network Connections menu was gone. Even without it will it be able to connect (maybe the menu is related to the driver, I'm not sure)? –  White Apr 16 '13 at 20:07
1  
You should be able to get connected to the internet, but you will need to use command line tools. Check if you can execute nmcli con in a terminal. –  Salem Apr 16 '13 at 20:15
    
After years trying, I was finally able (Yesterday. Nice timing, huh?) to get a decent internet (I got a 2MB cable. A whole lot better than a 50kb 3G xD), and it will be installed here this week. So I'll try your suggestion as soon as its working. If nothing works, then I'll just backup the big files and reinstall it. Since I can download things now it won't be such a big deal, and starting over may be useful, since I can do everything I should have done on the first time. –  White Apr 18 '13 at 3:03
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.