Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Deleted /var :(
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
8-bitDesigner
n00b
n00b


Joined: 14 Jan 2006
Posts: 25
Location: Orange, CA

PostPosted: Thu Feb 16, 2006 7:02 pm    Post subject: Reply with quote

Okay, that's a definite help, and I've just quickly sketched out a list of the merged packages I have installed (some 22, I believe, but I'll comb through my /usr/bin later).

So, just one package per line? Perfect.

Quick question, and I don't know if you'd know this one, but I just SSH'd in and I have an empty world file, so should I just copy over the header, or does the "$ head -n 10 /var/lib/portage/world" section change at all, from system to system?

Cheers and thanks for all the help so far!
Back to top
View user's profile Send private message
UncleOwen
Veteran
Veteran


Joined: 27 Feb 2003
Posts: 1493
Location: Germany, Hamburg

PostPosted: Thu Feb 16, 2006 7:51 pm    Post subject: Reply with quote

8-bitDesigner wrote:
Quick question, and I don't know if you'd know this one, but I just SSH'd in and I have an empty world file, so should I just copy over the header, or does the "$ head -n 10 /var/lib/portage/world" section change at all, from system to system?


That's just what I typed in the shell to get the list...
Back to top
View user's profile Send private message
8-bitDesigner
n00b
n00b


Joined: 14 Jan 2006
Posts: 25
Location: Orange, CA

PostPosted: Thu Feb 16, 2006 8:16 pm    Post subject: Reply with quote

Ah hah! Okay, now I remember the "head" command. I was expecting some sort of header on the world document itself, but just realised that it's not an executable, so, probably doesn't need one.

Don't mind me. :oops:
Back to top
View user's profile Send private message
tomk
Bodhisattva
Bodhisattva


Joined: 23 Sep 2003
Posts: 7221
Location: Sat in front of my computer

PostPosted: Thu Feb 16, 2006 10:20 pm    Post subject: Reply with quote

Merged from here.
_________________
Search | Read | Answer | Report | Strip
Back to top
View user's profile Send private message
8-bitDesigner
n00b
n00b


Joined: 14 Jan 2006
Posts: 25
Location: Orange, CA

PostPosted: Thu Feb 23, 2006 8:24 am    Post subject: Reply with quote

w00t! Back in business.

ecatmur's cruft script pumps out a list of files some many, many pages long, including a series of files for programs I've since emerged new versions of. So, I'm now going to dig through all that to figure out what I can make of all that data.

At least I'm running again! I emerged all the packages I'd installed since getting Gentoo up and running, and thankfully that seems to be everything.

I guess the only question I have now is, that I seem to be missing my /etc/make.profile/packages file, and I'm running 2005.1. Has this file moved, and if now, where can I find the packages installed by default so that I can add them to my world file?
Back to top
View user's profile Send private message
swooshOnLn
l33t
l33t


Joined: 28 Feb 2006
Posts: 741
Location: Charlotte, North Carolina

PostPosted: Fri Apr 28, 2006 5:39 pm    Post subject: Reply with quote

ok, what about a bash program that would "emerge --inject =(package name)" based on the folder names in "/usr/share/doc"?
_________________
"WARNING: you may LOL"

This is my font size, color, and signature. It will change to whatever I pick. How cool is that?
Back to top
View user's profile Send private message
synss
Apprentice
Apprentice


Joined: 08 Mar 2006
Posts: 282
Location: Dijon > Berlin > Tokyo > Nürnberg > München

PostPosted: Sun Apr 30, 2006 1:07 am    Post subject: Reply with quote

Hello, I pop in as I have just lost my /var tonight! (expanding the /var with fdisk, then want to resize my ext2 partition but it's gone...)

anyway, I have a quick workaround, I use portage 2.1, I do not know whether equery is part of it or not but... here we go, it is not perfect but it seems to help at least, please improve, I am poor with sed/awk, I know that
Code:
#!/bin/bash

cd /usr/share/doc
cat /dev/null > /tmp/a.file
mkdir -p /etc/portage/profile/
cat /dev/null > /etc/portage/profile/package.provided
for i in *-*
do
        query=$(ACCEPT_KEYWORDS="~x86" equery w "~$i")
        atom=$(echo "$query" | cut --delimiter=/ -f 4)/$(echo $query | cut --delimiter=/ -f 6 | sed s:.ebuild::)
        echo $atom
        echo $atom >> /tmp/a.file
        grep -vh '^/' /tmp/a.file > /tmp/b.file
done
cp /tmp/b.file /etc/portage/profile/package.provided


EDIT1:
1. I run a mixed x86/~x86 arch, hence the ACCEPT_KEYWORDS="~x86"
2. one could use atom=$(echo "$query" | cut --delimiter=/ -f 4)/$i on a x86 arch I believe
3. the grep -vh '^/' eliminates the equery failures
4. the rest is easy to understand: there is nothing else :wink:

EDIT2: It does help but it should work even better: I have app-misc/oneko-1.2 (running on my screen and) in /etc/portage/profile/package.provided, however, when I emerge -p oneko, it says it is new! I do not get that... But it is time to sleep now so I'll take care of that tomorrow. Good night. :sleep:

EDIT3: well, I'll go for a chroot re-install (I have a not-so-old backup of my world file and I know what softwares I use), but that trick *should* work better, I do not understand what is wrong there. Please tell me.

NOTE: the advantage on Windows here is that I can still watch DVDs during the reinstall process :lol:
Back to top
View user's profile Send private message
Drewgrange
Guru
Guru


Joined: 29 Mar 2003
Posts: 483
Location: Ohio, US

PostPosted: Mon Jun 12, 2006 5:43 am    Post subject: I deleted /var! Reply with quote

I just made a big boo boo

I was separating my filesystem out amoung separate partitions. I put /usr/portage in it's own filesystem, then wanted to put /var in one as well. Unfortunately I couldn't make another primary partition, so I just ran

Code:
mkdir /usr/portage/var
mv /var/* /usr/portage/var
rm -r /var
ln -s /usr/portage/var var


Everything was fine until I ran an emerge --sync. This deleted all of the var files! I know there are other things in var other than portage related entries such as /var/log... is there a way that I can restore this or am I screwed?

As for the partition.. I guess I should have made /var its own partition, then symlinked /usr/portage to /var/portage or something.
Back to top
View user's profile Send private message
bunder
Bodhisattva
Bodhisattva


Joined: 10 Apr 2004
Posts: 5934

PostPosted: Mon Jun 12, 2006 5:45 am    Post subject: Reply with quote

i think you're hosed. sorry. 8O
_________________
Neddyseagoon wrote:
The problem with leaving is that you can only do it once and it reduces your influence.

banned from #gentoo since sept 2017
Back to top
View user's profile Send private message
Drewgrange
Guru
Guru


Joined: 29 Mar 2003
Posts: 483
Location: Ohio, US

PostPosted: Mon Jun 12, 2006 5:50 am    Post subject: Reply with quote

well, luckily I moved my /home directory to it's own partition as well, so the most I'll lose here is some time.

damn, and this install has lasted me for about 3 years now!
Back to top
View user's profile Send private message
Dralnu
Veteran
Veteran


Joined: 24 May 2006
Posts: 1919

PostPosted: Mon Jun 12, 2006 6:04 am    Post subject: Reply with quote

Hmm, you might could attempt a recovery, but from my knowledge, a file recovery in Linux makes getting Windows to work smoothly look simple...
_________________
The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
Back to top
View user's profile Send private message
htranou
Tux's lil' helper
Tux's lil' helper


Joined: 08 May 2006
Posts: 96

PostPosted: Mon Jun 12, 2006 7:18 am    Post subject: Reply with quote

Putting aside the possible (?) recovery (not worth the hard work, if you ask me), Bunder is probably right.
You've lost your world file (it contains which packages you emerged), you can't try to regenerate it (regen-world uses emerge.log I think, that you've lost too), as well as the whole /var/db/pkg that contains the ebuilds of everything that is installed at the moment on your system.

There may be a couple other things, maybe in /var/lib. Maybe you had a /var/www ?

Well good luck on fixing your gentoo.

What you wanted to do wasn't bad in itself, but next time, you'll remember to use RSYNC_EXCLUDEFROM.
Back to top
View user's profile Send private message
Admiral_Trigger_Happy
Guru
Guru


Joined: 05 Sep 2004
Posts: 337
Location: Australia

PostPosted: Mon Jun 12, 2006 7:27 am    Post subject: Reply with quote

Yeah I lost my /var parition once too,
But luckly for me it was just after a fresh install so I just ran "emerge -ave system" and then reemerged the packages I had already installed.

You could do the same thing but I wouldn't advise it (too much crap would be left), I would suggest you backup the stuff in /etc that you have made changes to, like your make.conf, and the /etc/portage dir and of course /home and start from a fresh install with those files stuck in.

This give you a chance to refine somethings you would have liked to change, like your partition scheme etc.
_________________
Admiral Trigger Happy
-------------------------------
www.kiba-dock.org
Back to top
View user's profile Send private message
Dralnu
Veteran
Veteran


Joined: 24 May 2006
Posts: 1919

PostPosted: Mon Jun 12, 2006 9:12 am    Post subject: Reply with quote

Reinstall would probably be the least painful by far, plus you get to find out how well you REALLY know your computer :) (I know with my install I had alot of problems, being a first timer and all. Boy was that fun. Alot of satisfaction gained from your first working kernel).
_________________
The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
Back to top
View user's profile Send private message
gondolin
Apprentice
Apprentice


Joined: 09 Apr 2003
Posts: 158

PostPosted: Thu Nov 30, 2006 2:51 pm    Post subject: Lost /var Reply with quote

Hi,

I have an installed a corporate Gentoo local rsync server.
Now after the installation we take always image of the machine for a quick restore, but there was a bad interaction from one assistent that causes the erase of the /var partition.
Is there a way to fix this, example uses a /var from another machine? Its for the gentoo world file ... and so on.
I would not to reinstall the whole machine.

good ideas are more then welcome
Back to top
View user's profile Send private message
swooshOnLn
l33t
l33t


Joined: 28 Feb 2006
Posts: 741
Location: Charlotte, North Carolina

PostPosted: Thu Nov 30, 2006 3:11 pm    Post subject: Reply with quote

/var is a very important folder to loose.

I have seen some temp "works" for loosing /var, but I have not seen somebody fix it other than re-installing or using a backup.

If the other computers on the network are the exact same, you could try copying /var from one to the other.
_________________
"WARNING: you may LOL"

This is my font size, color, and signature. It will change to whatever I pick. How cool is that?
Back to top
View user's profile Send private message
nixnut
Bodhisattva
Bodhisattva


Joined: 09 Apr 2004
Posts: 10974
Location: the dutch mountains

PostPosted: Thu Nov 30, 2006 8:07 pm    Post subject: Reply with quote

merged above two posts here
_________________
Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered

talk is cheap. supply exceeds demand
Back to top
View user's profile Send private message
Dralnu
Veteran
Veteran


Joined: 24 May 2006
Posts: 1919

PostPosted: Thu Nov 30, 2006 8:56 pm    Post subject: Reply with quote

On an off-chance, maybe you could use another world file, place it in /var/whereitssupposedtobe/, then try emerge -e world?
_________________
The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
Back to top
View user's profile Send private message
gondolin
Apprentice
Apprentice


Joined: 09 Apr 2003
Posts: 158

PostPosted: Fri Dec 01, 2006 4:32 pm    Post subject: Reply with quote

A'm going to give that solution a try.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum