Difference between revisions of "Run an FSCK on your server"
(Created page with "<span data-link_translate_fr_title="Effectuer un FSCK sur votre serveur" data-link_translate_fr_url="Effectuer un FSCK sur votre serveur"></span>:fr:Effectuer un FSCK sur v...") |
(No difference)
|
Latest revision as of 05:34, 25 June 2023
fr:Effectuer un FSCK sur votre serveur
This article has been created by an automatic translation software. You can view the article source here.
Introduction: What is FSCK?
FSCK is the integrity check and repair tool for Linux file systems. This command is useful when you encounter problems with your OS: instability, crashes, etc.
Prerequisites
First of all, it's important to have a backup (this step is not compulsory, but strongly recommended). To do this, we recommend our Acronis : https://www.ikoula.com/fr/acronis-cloud-backup
Secondly, you will need to launch a netboot on your server. The way you do this depends on whether your server is virtualised or not.
- For a physical server, you need to go to the extranet interface (extranet.ikoula.com) and request a netboot using the button provided.
- If it's a virtualised server, you have two other options:
- On Hyper-V2 (Windows Server 2008), simply change the system boot image by choosing a Sysrescue CD, then reboot.
- On Hyper-V3 (Window Server 2012), as it is no longer possible to change the image on which to boot, you will need to contact technical support by ticket so that they can mount this image on your server.
- For more information on virtual server netbooting, please consult this article : Netboot sur serveur flex
Finally, if you would like more information on netbooting in general, we recommend this article Qu’est ce que le netboot et comment le lancer
Course
Once the prerequisites have been met, it will be useful to detect the partitions. Be careful not to mount partitions.
It will then be possible to run FSCK on the desired partition. For example, here is what the syntax would look like on the partition /dev/sda1
fsck -y /dev/sda1
The -y argument is used to directly validate the corrections made by FSCK. If this argument is not present, you will have to manually validate the changes made by FSCK.
The system will then return a report like this:
Passe 1 : vérification des i-noeuds, des blocs et des tailles
I-noeud 2392126, i_size est 77055, devrait être 110592. Corriger<o>? oui
I-noeud 2392126, i_blocs est 192, devrait être 224. Corriger<o>? oui
Passe 2 : vérification de la structure des répertoires
Passe 3 : vérification de la connectivité des répertoires
Passe 3A : optimisation des répertoires
Passe 4 : vérification des compteurs de référence
Passe 5 : vérification de l'information du sommaire de groupe
/dev/sda1: ***** LE SYSTÈME DE FICHIERS A ÉTÉ MODIFIÉ *****
/dev/sda1: 68816/6750208 files (0.9% non contigus), 12039728/13492584 blocs
FSCK will correct any anomalies it encounters at that time.
Conclusion
So you can now launch an FSCK via a netboot to correct system errors and problems.
Did you find this article useful?
Enable comment auto-refresher