Emmabuntüs Forum
Collectif pour le réemploi des ordinateurs et distribution Linux basée sur Debian

  Accueil -  Tutoriels -  Téléchargements -  Vidéos -  Interviews -  Qui sommes-nous -  Nous contacter -  Soutenir


My 4gb partition is recognized like 2gb

0 Membres et 1 Invité sur ce sujet

lusi

  • Newbie
  • *
    • Messages: 8
Good day for all:

I was installed EM DE4 (Bullseyes), initally the swap isn't mounted. I put this on fstab and recognize only 2gb from 4gb of partition. A temporal solution that I find is to create a swap file but I have 2gb of space without use.

Here are info about my system
https://paste.debian.net/1217473/
Filename Type Size Used Priority
/dev/sda2                              partition 2097148 1721892 -2
/dev/zram0                              partition 262140 262140 100
/home/luis/swap                        file    2097148 0 -3
https://paste.debian.net/1217474/
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 232,9G  0 disk
├─sda1   8:1    0 122,5G  0 part /home
├─sda2   8:2    0   3,7G  0 part [SWAP]
├─sda3   8:3    0  27,9G  0 part /
└─sda4   8:4    0  78,7G  0 part
sr0     11:0    1  1024M  0 rom 
zram0  253:0    0   256M  0 disk [SWAP]
Now the zram don't work I see.

Somebody can help me about?

Thanks
« Modifié: novembre 04, 2021, 10:22:41 pm par lusi »


alain-tux

  • Administrator
  • Full Member
  • *****
    • Messages: 222
Hello Lusi.

Can you give us the feedback of:
blkidcat /etc/fstab
These feedbacks, you can directly put them directly with tags "code", not necessary to go through the Debian server. For very long texts, yes, but there is little.
PC : Desktop HP Compaq 8200 Elite SFF PC | CPU : i7-2600 | RAM : 4GB | GPU : AMD RV730 PRO [Radeon HD 4650]
OS : emmade4 | Kernel: 5.10
In a world without walls and fences, who needs windows and gates?


lusi

  • Newbie
  • *
    • Messages: 8
Thanks Alain-tux for your reply:

The result of lsblk is:
/dev/sda1: UUID="edc4b296-f021-4022-a264-ab6f98adbebb" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="000487ae-01"
/dev/sda2: UUID="bc9cca80-8774-42e5-b0f1-dae84c1be63f" TYPE="swap" PARTUUID="000487ae-02"
/dev/sda3: UUID="1b5cfb57-c20b-40cd-9daa-3fffb20070a9" BLOCK_SIZE="4096" TYPE="ext4" PTTYPE="dos" PARTUUID="000487ae-03"
/dev/sda4: LABEL="Respaldos" UUID="f87b8d16-1b16-4402-9cab-65a391ee3814" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="000487ae-04"

The result of cat /etc/fstab is:
UUID=1b5cfb57-c20b-40cd-9daa-3fffb20070a9 /              ext4    defaults,noatime 0 1
UUID=edc4b296-f021-4022-a264-ab6f98adbebb /home          ext4    defaults,noatime 0 2
UUID=bc9cca80-8774-42e5-b0f1-dae84c1be63f swap           swap    defaults,noatime 0 2

Thanks in advance.
« Modifié: novembre 04, 2021, 10:24:12 pm par lusi »


alain-tux

  • Administrator
  • Full Member
  • *****
    • Messages: 222
Hello Lusi.

I'm not sure but try this in your FSTAB:

UUID=bc9cca80-8774-42e5-b0f1-dae84c1be63f none            swap    sw              0       0
The "swap" mounting point does not exist on my installation, But the option is populated "sw" or defaults", and dump & pass are populated as 0 0
« Modifié: novembre 04, 2021, 11:46:32 pm par alain-tux »
PC : Desktop HP Compaq 8200 Elite SFF PC | CPU : i7-2600 | RAM : 4GB | GPU : AMD RV730 PRO [Radeon HD 4650]
OS : emmade4 | Kernel: 5.10
In a world without walls and fences, who needs windows and gates?


Patrick

  • Administrator
  • Hero Member
  • *****
    • Messages: 978
    • Emmabuntüs The distribution sleek, accessible, equitable
Hi Alain and Lusi,

See my /etc/fstab :


# / was on /dev/sda1 during installation
UUID=c037aaf2-c086-4677-bff4-ed8782844c98 /               ext4    errors=remount-ro 0       1
# swap was on during /dev/sdb1 post-installation
UUID=6251a1bb-2532-4c36-8d3d-a6f0b92e6ac0 none            swap    sw              0       0


alain-tux

  • Administrator
  • Full Member
  • *****
    • Messages: 222
Like mine...exept the UUID of course  ;)
« Modifié: novembre 06, 2021, 11:38:53 pm par alain-tux »
PC : Desktop HP Compaq 8200 Elite SFF PC | CPU : i7-2600 | RAM : 4GB | GPU : AMD RV730 PRO [Radeon HD 4650]
OS : emmade4 | Kernel: 5.10
In a world without walls and fences, who needs windows and gates?


lusi

  • Newbie
  • *
    • Messages: 8
Thanks for your reply. 

I maked the chage on /etc/fstab/ but it remain equal on the space recongition. It shows only 2.25GB from almost 4GB. The partition of the disk I did make time ago and Ubuntu, I remember,  recognized the entire partition; I believe Mint too. I don't understand why EM do not recognize the entire partition.
« Modifié: novembre 08, 2021, 08:56:51 pm par lusi »


Patrick

  • Administrator
  • Hero Member
  • *****
    • Messages: 978
    • Emmabuntüs The distribution sleek, accessible, equitable
Hi Lusi,

how do you know that the swap only uses 2 GB of the 4 GB  ?

See this page : https://www.cyberciti.biz/faq/linux-check-swap-usage-command/

what say  Gparted and Htop ?



lusi

  • Newbie
  • *
    • Messages: 8
Good day Patrick.

I can't to post images here :(

The results for the command parted -l next

Model: ATA Hitachi HTS54322 (scsi)
Disk /dev/sda: 250GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags:

Number  Start   End     Size    Type     File system     Flags
 2      32,3kB  4001MB  4001MB  primary  linux-swap(v1)  <=== look here
 3      4001MB  34,0GB  30,0GB  primary  ext4
 4      34,0GB  119GB   84,5GB  primary  ext4            boot
 1      119GB   250GB   132GB   primary  ext4


Model: Unknown (unknown)
Disk /dev/zram0: 268MB
Sector size (logical/physical): 4096B/4096B
Partition Table: loop
Disk Flags:

Number  Start  End    Size   File system     Flags
 1      0,00B  268MB  268MB  linux-swap(v1)

The results for free -k              
total        used        free      shared  buff/cache   available
Mem:         3350880     2247544      361312      405568      742024      376888
Swap:        2359288      717756     1641532

Thanks in advance.

NB.:  finally I can upload two images.  I don't understand why disks to inform a size, parted other and gparted other.
« Modifié: novembre 13, 2021, 10:23:19 pm par lusi »


alain-tux

  • Administrator
  • Full Member
  • *****
    • Messages: 222
Hello Lusi

parted and disk gives GB or MB values while gparted gives them in GIB or MIB.
It's just a different way to calculate multiple.
The GB is 1000 x the MB, while the GIB is equal to 1 073 741 824 B. (10243)
A ratio of about 1.07 between GB and GIB.
In your case if gparted's 3.73 GIB multiplies by 1.07 we will get 4 GB of Disk and Parted.
The small difference you see between Parted and Disk of 1000 B (0.001MB) comes from the fact that Disk Rounded has a decimal. So 4.0 instead of 4.001. But it's the same unit of measure for Disk and Parted.
« Modifié: novembre 10, 2021, 01:11:42 am par alain-tux »
PC : Desktop HP Compaq 8200 Elite SFF PC | CPU : i7-2600 | RAM : 4GB | GPU : AMD RV730 PRO [Radeon HD 4650]
OS : emmade4 | Kernel: 5.10
In a world without walls and fences, who needs windows and gates?


lusi

  • Newbie
  • *
    • Messages: 8
Thanks alain-tux for the information, I do not know these.  But I remain in my problem: ¿Why EM don't recognize the entire swap partition?  :(.


alain-tux

  • Administrator
  • Full Member
  • *****
    • Messages: 222
Hello Lusi.

I am looking for why Free - K gives: 2359288 ... but for the moment I do not find the reason.
free -K gives a value in kib so lower than that in KB.
Try with:
free --KiloIt should give you a bit higher value (x 1.07) but it will never happen to your 4 gb ...
Sorry, but I can not understand where this problem is.
On my two computers under Emmade4 The Free command gives me good value.
I hope Patrick will be able to inform you. On my side, I continue to look for ...
PC : Desktop HP Compaq 8200 Elite SFF PC | CPU : i7-2600 | RAM : 4GB | GPU : AMD RV730 PRO [Radeon HD 4650]
OS : emmade4 | Kernel: 5.10
In a world without walls and fences, who needs windows and gates?


Patrick

  • Administrator
  • Hero Member
  • *****
    • Messages: 978
    • Emmabuntüs The distribution sleek, accessible, equitable
Hello Lusi and Alain,
Lusi did you follow this procedure to create the swap on your computer  https://fostips.com/create-remove-swap-file-debian/ ?


lusi

  • Newbie
  • *
    • Messages: 8
Yeap,  a curious something happen: I allocate 4g on the home partition but when I do sudo swapon ~/swap  always recognize only 2gb. I do not have space on / that's why  I assign it on the home.

htop shows 4.25gb and on the other hand swapon -s shows the next
Filename                                Type            Size    Used    Priority
/dev/sda2                               partition       2097148 1529008 -2
/dev/zram0                              partition       262140  262128  100
/home/luis/swap                         file            2097148 0       -3

The swapon command is the problematic then because mkswap ~/swap makes the work fine.
Setting up swapspace version 1, size = 4 GiB (4294963200 bytes)
no label, UUID=c0d82cc6-78e7-4547-8ced-fb9ea7427cf6

I don't understand.  At least I find the problematic command. The question is Why of this behavior? and How to fix it?
« Modifié: novembre 13, 2021, 11:58:02 pm par lusi »


Patrick

  • Administrator
  • Hero Member
  • *****
    • Messages: 978
    • Emmabuntüs The distribution sleek, accessible, equitable
Normally swap isn't on home partition and is on independent partition with name swap :

my swapon -s :

Filename Type Size Used Priority
/dev/sdc1                              partition 8193112 0 -2
/dev/zram0                              partition 65532 0 100
/dev/zram1                              partition 65532 0 100
/dev/zram2                              partition 65532 0 100
/dev/zram3                              partition 65532 0 100

see my config :




I think you have two 2GB swap files and that HTOP see only one swap area because it assembles both files simply.

If you want to see if you use more than 2 GB swap open a lot of windows and applications and look in HTOP if you exceed 2 GB use swap. If so, you have more than 2 GB of swap.

Do not worry about the swap one can operate operating systems without swap, and the main thing is that the PC does not hang.