Linux/manual

From Bgzashtita Official wiki
Revision as of 00:51, 25 July 2023 by Unknown user (talk)
Jump to navigation Jump to search


"sudo du -hsx / | sort -rh | head -20"

What's the output of `df -h | nc termbin.com 9999` ?


And this? sudo du -sh /var /usr /lib

du -sh /lib /home ==> check both lib and home as well

Your /var is a bit big too, maybe log is a lot; try: du -sh /var/* | sort -h

You may continue with `sudo du -sh /var/lib/* | sort -h` if you wish to pinpoint it


how to purge and install efi:

Okay, let's walk through the full steps start to finish to get your system booting properly again:

Boot from a Debian live USB/CD in UEFI mode.

Use fdisk or gdisk to verify your partition table - make sure you have partitions setup for EFI, root, and any others needed.

Format the EFI partition as FAT32 if needed.

Mount the root and EFI partitions:

mount /dev/nvme0n1p2 /mnt # Root partition mount /dev/nvme0n1p1 /mnt/boot/efi # EFI partition Chroot into the mounted root partition: chroot /mnt /bin/bash Install the GRUB and Linux packages: apt update


apt install grub-efi-amd64 grub-common linux-image-amd64 Generate an initramfs image: update-initramfs -c -k all Verify the kernel and initrd files now exist in /boot

Edit /etc/fstab to match partitions if needed.

Generate a GRUB config file and reinstall GRUB:

grub-mkconfig -o /boot/grub/grub.cfg grub-install update-grub Reboot and verify you can boot into GRUB and then Linux! Let's take it step-by-step. Let me know if you get stuck or have any errors at any point in the process.




Pissed: with every new version ubuntu IS SHIT:


So on ubuntu 23.04 there is pain in all body, as they change ip static changes: It is not like classic unknown where put code, it is in yaml and it use netplan, not restarting networwking. So here is config:


nano /etc/netplan/00-installer-config.yaml                                                  
  1. This is the network config written by 'subiquity'

network:

 ethernets:
       ens160:
           addresses: ['192.168.3.237/24']
           gateway4: 192.168.3.1
           nameservers:
               addresses: [192.168.3.1, 8.8.4.4, 8.8.8.8]
               search: [localdomain]
 version: 2


After safe and exit

Now here is SHIT CATCH:


to apply for getting ip:

get admin rights and write:


netplan apply


now you have internet: