On 2023-04-28 at 20:46, Jeremy Ardley wrote:

> On 29/4/23 08:25, Maureen L Thomas wrote:
>
>> I am 72 and have forgotten a few things.  I looked up debian/var and 
>> was told I could delete /var/log/
>>
>> and /var/tmp/ and /var/cores/.

I'd guess that this was *probably* meant as a direction to delete *files
from inside* those directories. Deleting the directories themselves, or
even deleting their contents wholesale, can - as you've discovered -
create a problematic circumstance.

>> I left cores alone and deleted the other two.  Now I cannot burn a
>> backup, download files and even go to web sites from my nord vpn
>> which was working great until I deleted the above files.  I really
>> want to upgrade to debian 11. I am using debian 10, on a Lonovo all
>> in one and have had no problems.  I followed the directions for var
>> that I found and now have a screwed up machine.  Is there any help
>> available. I was thinking of upgrading online but don't want to
>> loose my data. Please help this old lady.
>>
>>
> Deleting /var/log etc is at best unhelpful.
> 
> I can't think of any procedure that would require deleting those 
> directories. Perhaps someone was fooling with you?
> 
> Without knowing what else you have done or why, it's probably a good 
> idea to recreate the directories
> 
> cd /var
> 
> mkdir log
> 
> mkdir tmp

That won't necessarily bring back the correct directory permissions, or
any needed subdirectory structure under these two locations.

I'm not *positive* that this won't break anything, but I think the
safest thing to do would probably be to reinstall the 'base-files'
package, which can *probably* still be done - even on a system with
those directories missing - with 'dpkg -i' from the copy in
/var/cache/apt/archives/.

That should, I think, bring back both directories with any needed
permissions. It will not, however, re-create any subdirectories (e.g.
under /var/log/) which were created by other packages; for that, you'd
have to reinstall those packages as well.

Given that one of the directories on my own system is /var/log/apt/,
it's not impossible that much of the package-management system may not
work (fully) correctly until you've identified and reinstalled the
correct packages.

-- 
   The Wanderer

The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all
progress depends on the unreasonable man.         -- George Bernard Shaw

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to