exporting git files
-
- Posts: 3
- Joined: 2024/02/23 10:17:40
exporting git files
Hi there.
My friend gave me a very neat desktop, and said i can keep it if i manage to bypass the root password and save his github projects from the drive.
Password, piece of cake, but i'm a debian guy, and this computer has been used as a server. I have 2x 1TB SSD drives, and i would like to write the existing system to one of them and simply hand over the SSD to my friend. But i'm worried i will mess things up which will result in me not getting to keep this very nice computer.
I have no experience with Oracle and centos, and only a tiny bit experience with servers.
My issue is that the system is divided on multiple virtual machines and locations.
Could anyone point out to me which specific folders i need to copy/export?
The system is showing the SSD's as a single 2TB Block device.
Now i'm not even able to access internet with this thing...
Here is lshw -c disk output
root@localhost oracle]# lshw-c disk
*-disk
description: ATA Disk
product: tigo SSD 1TB
physical id: 0.0.0
bus info: scsi@1:0.0.0
logical name: /dev/sda
version: 440
serial: TC225280M2A0006
size: 953GiB (1024GB)
capabilities: partitioned partitioned: dos
configuration: ansiversion=5 logicalsectorsize=512 sectorsize=512 signature=000c67ee
*-disk
description: ATA Disk
product: tigo SSD 1TB
physical id: 0.0.0
bus info: scsi@9:0.0.0
logical name: /dev/sdb
version: 4ΑΘ
serial: TC225280M2A0014
size: 953G1B (1024GB)
capabilities: partitioned partitioned:dos
configuration: ansiversion=5 logicalsectorsize=512 sectorsize=512 signature=000a40fd
My friend gave me a very neat desktop, and said i can keep it if i manage to bypass the root password and save his github projects from the drive.
Password, piece of cake, but i'm a debian guy, and this computer has been used as a server. I have 2x 1TB SSD drives, and i would like to write the existing system to one of them and simply hand over the SSD to my friend. But i'm worried i will mess things up which will result in me not getting to keep this very nice computer.
I have no experience with Oracle and centos, and only a tiny bit experience with servers.
My issue is that the system is divided on multiple virtual machines and locations.
Could anyone point out to me which specific folders i need to copy/export?
The system is showing the SSD's as a single 2TB Block device.
Now i'm not even able to access internet with this thing...
Here is lshw -c disk output
root@localhost oracle]# lshw-c disk
*-disk
description: ATA Disk
product: tigo SSD 1TB
physical id: 0.0.0
bus info: scsi@1:0.0.0
logical name: /dev/sda
version: 440
serial: TC225280M2A0006
size: 953GiB (1024GB)
capabilities: partitioned partitioned: dos
configuration: ansiversion=5 logicalsectorsize=512 sectorsize=512 signature=000c67ee
*-disk
description: ATA Disk
product: tigo SSD 1TB
physical id: 0.0.0
bus info: scsi@9:0.0.0
logical name: /dev/sdb
version: 4ΑΘ
serial: TC225280M2A0014
size: 953G1B (1024GB)
capabilities: partitioned partitioned:dos
configuration: ansiversion=5 logicalsectorsize=512 sectorsize=512 signature=000a40fd
Re: exporting git files
"lsblk" may provide more information.
Re: exporting git files
A real "github project" would have a a copy of the repo in GitHub that he should be able to access from any computer.
One could also ask why the friend did not copy the files self, being familiar with the system and all?
Default partitioning on EL systems has four/five filesystems:bukkake151 wrote: ↑2024/02/23 11:08:05My issue is that the system is divided on multiple virtual machines and locations.
/boot/efi (if UEFI is used)
/boot
/
/home
swap
The latter three are LVM2 logical volumes (LV). A VG -- and thus LV -- can span multiple physical devices.
The lsblk does indeed tell more. (Also lsblk --fs for extra details.)
Virtual machines -- guests -- are separate "computers". On the host the disk space that they use is a file or volume.
The host can show what VM guests it has with: virsh list --all
-
- Posts: 3
- Joined: 2024/02/23 10:17:40
Re: exporting git files
Now a bit wiser i can add some details. It's a LVM blockdevice on 2 separate SSD's. Didn't know what LVM is until yesterday.jlehtone wrote: ↑2024/02/23 14:37:13A real "github project" would have a a copy of the repo in GitHub that he should be able to access from any computer.
One could also ask why the friend did not copy the files self, being familiar with the system and all?
Default partitioning on EL systems has four/five filesystems:bukkake151 wrote: ↑2024/02/23 11:08:05My issue is that the system is divided on multiple virtual machines and locations.
/boot/efi (if UEFI is used)
/boot
/
/home
swap
The latter three are LVM2 logical volumes (LV). A VG -- and thus LV -- can span multiple physical devices.
The lsblk does indeed tell more. (Also lsblk --fs for extra details.)
Virtual machines -- guests -- are separate "computers". On the host the disk space that they use is a file or volume.
The host can show what VM guests it has with: virsh list --all
If i understood correct i can shrink the blockdevice to fit one of the SSD's, leaving the other one untouched? this would be ideal.
Re: exporting git files
That depends. You can see what filesystems you have with:bukkake151 wrote: ↑2024/02/27 13:34:09If i understood correct i can shrink the blockdevice to fit one of the SSD's, leaving the other one untouched?
Code: Select all
lsblk --fs
LV is a "list of blocks" -- bit like a plain partition. Filesystem has data in those blocks.
If one simply updates "last block" of LV/partition for "shrink", then all the blocks after the new end are now "outside" and if filesystem had any data on them, that will become lost.
That is why one has to first tell the filesystem to not use more than N blocks, and only after that change the size of LV to N blocks.
The lvreduce does have option --resizefs that does the necessary filesystem step.
However, there is no shrink operation of filesystem of type "XFS". For it the process is to copy files to backup, remove filesystem, create smaller filesystem, and finally restore files from backup.
Re: exporting git files
Run the commands:bukkake151 wrote: ↑2024/02/27 13:34:09
Now a bit wiser i can add some details. It's a LVM blockdevice on 2 separate SSD's. Didn't know what LVM is until yesterday.
If i understood correct i can shrink the blockdevice to fit one of the SSD's, leaving the other one untouched? this would be ideal.
Code: Select all
pvdisplay
vgdisplay
"lvdisplay" will list the logical volumes (these will also show up in lsblk), and you may find that you can remove one or more logical volumes to free sufficient space to remove a physical volume. However, take great care with this, since usage of a logical volume may not be obvious.
-
- Posts: 3
- Joined: 2024/02/23 10:17:40
Re: exporting git files
Thanks everyone for your replies. I found a super easy solution with 100% success rate: I bought myself a brand new 1Tb SSD, it's running like a charm.