[Solved]Could a whole disk be added into a partition, another PC?  [Solved]

Message
Author
User avatar
keos
Posts: 1394
Joined: Sat Mar 04, 2017 12:00 pm

[Solved]Could a whole disk be added into a partition, another PC?

#1 Post by keos »

Hello,

I have already copied an MXLinux that I installed, on a whole disk in one PC, means without partitioning it, to a USB, and I need to know 'if it' (the USB) can be added to a partition into another PC.

With Gparted, it cannot be “pasted” and via the commands using 'dd' either, since I have to indicate the path where it goes and this should be “unassigned”, I suppose there must be some other way to do it, is this not possible? :alien:

Thanks.

Code: Select all

keos@localhost:~> inxi -fxxxrz
CPU:
  Info: quad core model: 11th Gen Intel Core i7-1165G7 bits: 64 type: MT MCP
    smt: enabled arch: Tiger Lake rev: 1 cache: L1: 320 KiB L2: 5 MiB L3: 12 MiB
  Speed (MHz): avg: 564 high: 1208 min/max: 400/4700 cores: 1: 1208 2: 400
    3: 400 4: 400 5: 400 6: 400 7: 906 8: 400 bogomips: 44864
  Flags: 3dnowprefetch abm acpi adx aes aperfmperf apic arat
    arch_capabilities arch_perfmon art avx avx2 avx512_bitalg avx512_vbmi2
    avx512_vnni avx512_vp2intersect avx512_vpopcntdq avx512bw avx512cd
    avx512dq avx512f avx512ifma avx512vbmi avx512vl bmi1 bmi2 bts cat_l2
    cdp_l2 clflush clflushopt clwb cmov constant_tsc cpuid cpuid_fault cx16
    cx8 de ds_cpl dtes64 dtherm dts epb ept ept_ad erms est f16c flexpriority
    flush_l1d fma fpu fsgsbase fsrm fxsr gfni ht hwp hwp_act_window hwp_epp
    hwp_notify hwp_pkg_req ibpb ibrs ibrs_enhanced ibt ida intel_pt invpcid
    lahf_lm lm mca mce md_clear mmx monitor movbe movdir64b movdiri msr mtrr
    nonstop_tsc nopl nx ospke pae pat pbe pcid pclmulqdq pdcm pdpe1gb pebs
    pge pku pln pni popcnt pse pse36 pts rdpid rdrand rdseed rdt_a rdtscp
    rep_good sdbg sep sha_ni smap smep split_lock_detect ss ssbd sse sse2
    sse4_1 sse4_2 ssse3 stibp syscall tm tm2 tpr_shadow tsc tsc_adjust
    tsc_deadline_timer tsc_known_freq umip vaes vme vmx vnmi vpclmulqdq vpid
    x2apic xgetbv1 xsave xsavec xsaveopt xsaves xtopology xtpr
Repos:
  Packages: pm: rpm pkgs: N/A note: see --rpm
  Active zypp repos in: /etc/zypp/repos.d/download.opensuse.org-non-oss.repo
    1: download.opensuse.org-non-oss ~ http://download.opensuse.org/tumbleweed/repo/non-oss/
  Active zypp repos in: /etc/zypp/repos.d/download.opensuse.org-oss.repo
    1: download.opensuse.org-oss ~ http://download.opensuse.org/tumbleweed/repo/oss/
  Active zypp repos in: /etc/zypp/repos.d/download.opensuse.org-tumbleweed.repo
    1: download.opensuse.org-tumbleweed ~ http://download.opensuse.org/update/tumbleweed/
  Active zypp repos in: /etc/zypp/repos.d/home_AndnoVember_test.repo
    1: home_AndnoVember_test ~ https://download.opensuse.org/repositories/home:/AndnoVember:/test/openSUSE_Leap_15.3/
  Active zypp repos in: /etc/zypp/repos.d/home_ponchale1.repo
    1: home_ponchale1 ~ https://download.opensuse.org/repositories/home:/ponchale1/openSUSE_Tumbleweed/
  Active zypp repos in: /etc/zypp/repos.d/openSUSE-20240813-0.repo
    1: openSUSE-20240813-0 ~ http://download.opensuse.org/tumbleweed/repo/oss/
  No active zypp repos in: /etc/zypp/repos.d/repo-debug.repo
  Active zypp repos in: /etc/zypp/repos.d/repo-openh264.repo
    1: repo-openh264 ~ http://codecs.opensuse.org/openh264/openSUSE_Tumbleweed
  No active zypp repos in: /etc/zypp/repos.d/repo-source.repo
  Active zypp repos in: /etc/zypp/repos.d/yandex-browser.repo
    1: yandex-browser ~ http://repo.yandex.ru/yandex-browser/rpm/stable/x86_64
keos@localhost:~>
Last edited by keos on Sat Sep 07, 2024 3:10 am, edited 2 times in total.
Acer Aspire A315-58
Intel Core i7-1165G7
Iris Xe Graphics
MX-23.2-Xfce4 - 4.18.2

*Matthew 5:11

User avatar
Eadwine Rose
Administrator
Posts: 14649
Joined: Wed Jul 12, 2006 2:10 am

Re: Could a whole disk be added into a partition, another PC?

#2 Post by Eadwine Rose »

With all help requests, please share your full Quick System Info, found in the menu under Favorites. Press the Copy for forum button, then click paste in a reply. If need be, you can do this with the LiveUSB, thanks.

Topic moved, not a tip or trick shared.
MX-23.6_x64 July 31 2023 * 6.1.0-37amd64 ext4 Xfce 4.20.0 * 8-core AMD Ryzen 7 2700
Asus TUF B450-Plus Gaming UEFI * Asus GTX 1050 Ti Nvidia 535.247.01 * 2x16Gb DDR4 2666 Kingston HyperX Predator
Samsung 870EVO * Samsung S24D330 & P2250 * HP Envy 5030

User avatar
MadMax
Posts: 483
Joined: Wed Aug 04, 2021 3:25 pm

Re: Could a whole disk be added into a partition, another PC?

#3 Post by MadMax »

This is not the QSI....

There's some approaches to copy a whole disk with or without partition table to another disk via dd. The gist of it is that the target block device has to be exactly the same size or larger to copy successfully. You can also copy block devices (disks or partitions) to (new) files within a filesystem instead of block devices. That's most useful for backups.

Can you post outputs of lsblk -f of both PCs and one with connected usb drive to show an overview of what's available?

Another question is what do you want to accomplish with the copy? Getting it to boot might involve additional steps.
Last edited by MadMax on Sat Aug 31, 2024 7:25 am, edited 1 time in total.
If it ain't broke, don't fix it.
Main: MX 23 | Second: Mint 22 | HTPC: Linux Lite 7 | VM Machine: Debian 12 | Testrig: Arch/FreeBSD 14 | Work: RHEL 8

User avatar
Eadwine Rose
Administrator
Posts: 14649
Joined: Wed Jul 12, 2006 2:10 am

Re: Could a whole disk be added into a partition, another PC?

#4 Post by Eadwine Rose »

It is an alternative to the QSI, it is on antix.

Code: Select all

inxi -fxxxrza

is the full QSI command that gets executed.
MX-23.6_x64 July 31 2023 * 6.1.0-37amd64 ext4 Xfce 4.20.0 * 8-core AMD Ryzen 7 2700
Asus TUF B450-Plus Gaming UEFI * Asus GTX 1050 Ti Nvidia 535.247.01 * 2x16Gb DDR4 2666 Kingston HyperX Predator
Samsung 870EVO * Samsung S24D330 & P2250 * HP Envy 5030

User avatar
keos
Posts: 1394
Joined: Sat Mar 04, 2017 12:00 pm

Re: Could a whole disk be added into a partition, another PC?

#5 Post by keos »

First of all I want to make myself understood.

I have a complete system already copied to a USB, this system was installed on the entire disk of a PC.

Now I am going to add more memory to that PC (it has only 16GB) and later I'm going to make the partition the disk, so I need to know how I can, if it is possible, to add, to one of the partitions that I will create, 'what is' on the USB (the whole disk of that ...).

I don't want to confuse you by giving you information that may not be related to the matter at the moment. I need to know first if you understand what I intend to do because it may not be possible.

Thanks
Acer Aspire A315-58
Intel Core i7-1165G7
Iris Xe Graphics
MX-23.2-Xfce4 - 4.18.2

*Matthew 5:11

User avatar
MadMax
Posts: 483
Joined: Wed Aug 04, 2021 3:25 pm

Re: Could a whole disk be added into a partition, another PC?

#6 Post by MadMax »

keos wrote: Sat Aug 31, 2024 8:15 amI have a complete system already copied to a USB, this system was installed on the entire disk of a PC.
Ok, so far so good. That's a full copy of the local disk including the partition table done by the likes of dd if=/dev/sdX of=/dev/sdY
keos wrote: Sat Aug 31, 2024 8:15 amNow I am going to add more memory to that PC (it has only 16GB) ...
Memory has nothing to do with the disks/block devices, you can do that without changing any data.
keos wrote: Sat Aug 31, 2024 8:15 am... later I'm going to make the partition the disk, so I need to know how I can, if it is possible, to add, to one of the partitions that I will create, 'what is' on the USB (the whole disk of that ...).
Not sure what you mean by that tbh.
If it ain't broke, don't fix it.
Main: MX 23 | Second: Mint 22 | HTPC: Linux Lite 7 | VM Machine: Debian 12 | Testrig: Arch/FreeBSD 14 | Work: RHEL 8

User avatar
keos
Posts: 1394
Joined: Sat Mar 04, 2017 12:00 pm

Re: Could a whole disk be added into a partition, another PC?

#7 Post by keos »

Ah, maybe this is the essential point that lends itself to confusion if I don't explain myself better; by having more memory in the PC I will be able to install other systems, “if,” I erase absolutely everything (that's why I copied the system to a USB)...

Then, I will do a new partitioning ... is it possible to install in one these new partitions that system that I have in the USB? -- I am afraid it is not possible, am I wrong?.
Acer Aspire A315-58
Intel Core i7-1165G7
Iris Xe Graphics
MX-23.2-Xfce4 - 4.18.2

*Matthew 5:11

User avatar
MadMax
Posts: 483
Joined: Wed Aug 04, 2021 3:25 pm

Re: Could a whole disk be added into a partition, another PC?

#8 Post by MadMax »

If you are talking about dual or multi booting, 16 GB of RAM is enough to run every OS, so that wouldn't really be necessary, but ok.

If you want to re-partition the PC's drive that's another story. Since you will be giving up space for new partitions, you will run out of space to copy the old partitions back from the usb stick afterwards. They'd have to be shrunk first which is a whole other task depending on available space and the file systems in use. I strongly recommend getting a bigger drive if that's what you're planning. This would have the advantage that you still had your old drive as additional backup.

An alternative approach would be to copy data from within the partitions of the usb stick to a newly created partition via a tool like rsync (-avx). I moved full (and running, but this might not be recommended) installations from HDD to SSD like that before. The caveat is that you have to adjust your fstab file within the copy afterwards and also install or update your bootloader manually in a chroot environment to make the new system bootable.
If it ain't broke, don't fix it.
Main: MX 23 | Second: Mint 22 | HTPC: Linux Lite 7 | VM Machine: Debian 12 | Testrig: Arch/FreeBSD 14 | Work: RHEL 8

User avatar
keos
Posts: 1394
Joined: Sat Mar 04, 2017 12:00 pm

Re: Could a whole disk be added into a partition, another PC?

#9 Post by keos »

What was recommended to me to change -- on another site/forum -- was this ...:

https://www.amazon.com/dp/B076P63R3N?

EDIT:

By the way,

This is the machine on which I intend to make the change and the system I would like to keep:

Code: Select all

[CODE]System:
  Kernel: 6.10.6-2-liquorix-amd64 [6.10-6~mx23ahs] arch: x86_64 bits: 64 compiler: gcc v: 12.2.0 parameters: audit=0
    intel_pstate=disable BOOT_IMAGE=/boot/vmlinuz-6.10.6-2-liquorix-amd64 root=UUID=<filter> ro
    quiet splash
  Desktop: Xfce v: 4.18.1 tk: Gtk v: 3.24.36 info: xfce4-panel wm: xfwm v: 4.18.0 vt: 7
    dm: LightDM v: 1.26.0 Distro: MX-23.3_ahs_x64 Libretto January 21  2024 base: Debian GNU/Linux
    12 (bookworm)
Machine:
  Type: Laptop System: GOOGLE product: Peppy v: 1.0 serial: <superuser required> Chassis: type: 9
    serial: <superuser required>
  Mobo: GOOGLE model: Peppy v: 1.0 serial: <superuser required> UEFI: coreboot
    v: MrChromebox-4.17.2 date: 07/18/2022
Battery:
  ID-1: BAT0 charge: 32.7 Wh (100.0%) condition: 32.7/44.7 Wh (73.1%) volts: 12.7 min: 11.4
    model: SONYCor AP13J4K type: Li-ion serial: <filter> status: full cycles: 230
CPU:
  Info: model: Intel Celeron 2955U bits: 64 type: MCP arch: Haswell level: v2 built: 2013-15
    process: Intel 22nm family: 6 model-id: 0x45 (69) stepping: 1 microcode: 0x26
  Topology: cpus: 1x cores: 2 smt: <unsupported> cache: L1: 128 KiB desc: d-2x32 KiB; i-2x32 KiB
    L2: 512 KiB desc: 2x256 KiB L3: 2 MiB desc: 1x2 MiB
  Speed (MHz): avg: 1397 min/max: 800/1400 scaling: driver: acpi-cpufreq governor: ondemand
    cores: 1: 1397 2: 1397 bogomips: 5586
  Flags: ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
  Vulnerabilities:
  Type: gather_data_sampling status: Not affected
  Type: itlb_multihit status: KVM: VMX disabled
  Type: l1tf mitigation: PTE Inversion; VMX: conditional cache flushes, SMT disabled
  Type: mds mitigation: Clear CPU buffers; SMT disabled
  Type: meltdown mitigation: PTI
  Type: mmio_stale_data status: Unknown: No mitigations
  Type: reg_file_data_sampling status: Not affected
  Type: retbleed status: Not affected
  Type: spec_rstack_overflow status: Not affected
  Type: spec_store_bypass mitigation: Speculative Store Bypass disabled via prctl
  Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2 mitigation: Retpolines; IBPB: conditional; IBRS_FW; STIBP: disabled; RSB
    filling; PBRSB-eIBRS: Not affected; BHI: Not affected
  Type: srbds mitigation: Microcode
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: Intel Haswell-ULT Integrated Graphics driver: i915 v: kernel arch: Gen-7.5
    process: Intel 22nm built: 2013 ports: active: eDP-1 empty: HDMI-A-1 bus-ID: 00:02.0
    chip-ID: 8086:0a06 class-ID: 0300
  Device-2: Sunplus Innovation HD WebCam type: USB driver: uvcvideo bus-ID: 1-3:2
    chip-ID: 1bcf:2c67 class-ID: 0e02
  Display: x11 server: X.Org v: 1.21.1.7 compositor: xfwm v: 4.18.0 driver: X:
    loaded: modesetting unloaded: fbdev,vesa dri: crocus gpu: i915 display-ID: :0.0 screens: 1
  Screen-1: 0 s-res: 1366x768 s-dpi: 96 s-size: 361x203mm (14.21x7.99") s-diag: 414mm (16.31")
  Monitor-1: eDP-1 model: ChiMei InnoLux 0x1132 built: 2013 res: 1366x768 hz: 60 dpi: 136
    gamma: 1.2 size: 256x144mm (10.08x5.67") diag: 294mm (11.6") ratio: 16:9 modes: 1366x768
  API: OpenGL v: 4.6 Mesa 23.1.2-1~mx23ahs renderer: Mesa Intel HD Graphics (HSW GT1)
    direct-render: Yes
Audio:
  Device-1: Intel Haswell-ULT HD Audio driver: snd_hda_intel v: kernel bus-ID: 00:03.0
    chip-ID: 8086:0a0c class-ID: 0403
  Device-2: Intel 8 Series HD Audio driver: snd_hda_intel v: kernel bus-ID: 00:1b.0
    chip-ID: 8086:9c20 class-ID: 0403
  API: ALSA v: k6.10.6-2-liquorix-amd64 status: kernel-api tools: alsamixer,amixer
  Server-1: PipeWire v: 1.0.0 status: active with: 1: pipewire-pulse status: active
    2: wireplumber status: active 3: pipewire-alsa type: plugin 4: pw-jack type: plugin
    tools: pactl,pw-cat,pw-cli,wpctl
Network:
  Device-1: Qualcomm Atheros AR9462 Wireless Network Adapter vendor: Foxconn driver: ath9k
    v: kernel modules: wl pcie: gen: 1 speed: 2.5 GT/s lanes: 1 bus-ID: 01:00.0 chip-ID: 168c:0034
    class-ID: 0280
  IF: wlan0 state: up mac: <filter>
Bluetooth:
  Device-1: Foxconn / Hon Hai type: USB driver: btusb v: 0.8 bus-ID: 1-4:4 chip-ID: 0489:e056
    class-ID: e001
  Report: hciconfig ID: hci0 rfk-id: 1 state: up address: <filter> bt-v: 2.1 lmp-v: 4.0 sub-v: 1
    hci-v: 4.1 rev: 1102
  Info: acl-mtu: 1022:8 sco-mtu: 183:5 link-policy: rswitch hold sniff
    link-mode: peripheral accept service-classes: rendering, capturing, audio, telephony
Drives:
  Local Storage: total: 14.91 GiB used: 11.14 GiB (74.7%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/sda maj-min: 8:0 vendor: Kingston model: SNS4151S316G size: 14.91 GiB block-size:
    physical: 512 B logical: 512 B speed: 6.0 Gb/s type: SSD serial: <filter> rev: 01.1 scheme: GPT
Partition:
  ID-1: / raw-size: 14.66 GiB size: 14.33 GiB (97.74%) used: 11.14 GiB (77.7%) fs: ext4
    dev: /dev/sda2 maj-min: 8:2
  ID-2: /boot/efi raw-size: 256 MiB size: 252 MiB (98.46%) used: 274 KiB (0.1%) fs: vfat
    dev: /dev/sda1 maj-min: 8:1
Swap:
  Kernel: swappiness: 15 (default 60) cache-pressure: 100 (default)
  ID-1: swap-1 type: file size: 2 GiB used: 0 KiB (0.0%) priority: -2 file: /swap/swap
Sensors:
  System Temperatures: cpu: 48.0 C pch: 100.0 C mobo: N/A
  Fan Speeds (RPM): N/A
Repos:
  Packages: pm: dpkg pkgs: 2328 libs: 1265 tools: apt,apt-get,aptitude,nala,synaptic pm: rpm
    pkgs: 0
  No active apt repos in: /etc/apt/sources.list
  Active apt repos in: /etc/apt/sources.list.d/debian-stable-updates.list
    1: deb http://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware
  Active apt repos in: /etc/apt/sources.list.d/debian.list
    1: deb http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware
    2: deb http://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware
  Active apt repos in: /etc/apt/sources.list.d/mx.list
    1: deb http://mirrors.rit.edu/mxlinux/mx-packages/mx/repo/ bookworm main non-free
    2: deb http://mirrors.rit.edu/mxlinux/mx-packages/mx/repo/ bookworm ahs
  Active apt repos in: /etc/apt/sources.list.d/yandex-browser.list
    1: deb [arch=amd64] https://repo.yandex.ru/yandex-browser/deb stable main
Info:
  Processes: 274 Uptime: 9m wakeups: 3 Memory: 3.71 GiB used: 1.6 GiB (43.2%) Init: SysVinit
  v: 3.06 runlevel: 5 default: graphical tool: systemctl Compilers: gcc: 12.2.0 alt: 12
  Client: shell wrapper v: 5.2.15-release inxi: 3.3.26
Boot Mode: UEFI
[/code]
Last edited by keos on Sat Aug 31, 2024 10:00 am, edited 1 time in total.
Acer Aspire A315-58
Intel Core i7-1165G7
Iris Xe Graphics
MX-23.2-Xfce4 - 4.18.2

*Matthew 5:11

User avatar
MadMax
Posts: 483
Joined: Wed Aug 04, 2021 3:25 pm

Re: Could a whole disk be added into a partition, another PC?

#10 Post by MadMax »

Yes, that's a SSD aka the disk. No RAM/memory. Make sure your system supports M.2 format before buying one.

If you want to boot different OS' and tinker with multiboot 120 GB is probably not enough, I'd recommend AT LEAST 240 GB, better more. Calculate about 40-50 GB per OS.
If it ain't broke, don't fix it.
Main: MX 23 | Second: Mint 22 | HTPC: Linux Lite 7 | VM Machine: Debian 12 | Testrig: Arch/FreeBSD 14 | Work: RHEL 8

Post Reply

Return to “antiX”