Code Monkey home page Code Monkey logo

Comments (34)

Philtass avatar Philtass commented on September 27, 2024 1

I run rpi-clone, it seems to work (it's long)

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024 1

done successfully ! The problem came from the SD card I guess

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024 1

Thanks for help and advices !

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

PS: last successfull save was 19th january 2023

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

I did'nt check logs before today, shame on me !

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

Thank's for fixing or tell me what to do for

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

Hi @Philtass, can you confirm that the devices exists with the command:
sudo fdisk -l

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

Hi viniciuspaes !
sudo fdisk -l gives (at the end):
...
Disk /dev/sda: 29,8 GiB, 32010928128 bytes, 62521344 sectors
Disk model: Storage Device
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

Looking the log you have the OS installed in the SD card (/dev/mmcblk0)
Then /dev/mmcblk0p1 is the boot partition and /dev/mmcblk0p2 is the OS.

You want to clone everything to the SDA (assuming external drive). The RPI clone is not recognizing the label for SDA.

The command you used to clone was:
sudo rpi-clone sda

Correct?

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

Yes

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

previously I used "sudo rpi-clone sda -U" with same result

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

It is weird that even parted is not recognizing SDA.

Double check if the command output the partitions:
cat /proc/partitions

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

$ cat /proc/partitions
major minor #blocks name

1 0 4096 ram0
1 1 4096 ram1
1 2 4096 ram2
1 3 4096 ram3
1 4 4096 ram4
1 5 4096 ram5
1 6 4096 ram6
1 7 4096 ram7
1 8 4096 ram8
1 9 4096 ram9
1 10 4096 ram10
1 11 4096 ram11
1 12 4096 ram12
1 13 4096 ram13
1 14 4096 ram14
1 15 4096 ram15
179 0 7815168 mmcblk0
179 1 262144 mmcblk0p1
179 2 7544832 mmcblk0p2
8 0 31260672 sda

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

Just googled and saw some issues with parted. It is possible to create the label manually in case of corrupted or unrecognized disk label.

Have you tried to format the external disk manually already, to see the results?

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

Not for the moment. I'm not sure of parameters.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

I see sda1 should be a fat32 and sda2 an ext3 but I never used command line to format a disk. I don't want to make a mess.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

Coul'd you give the right commands ?

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

Plug the external drive in your desktop computer. If using windows, try to format the drive and do some tests.

Then plug it again in the RPi and try the clone process. I did this way with my RPi 4 and worked in the first try.

Don't worry about creating the partitions, just check if the drive is working properly first.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

I use linux. Have you a command line to format..

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

Sure, hang on.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

Ok try that

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

To erase the external drive (double check if the external drive is mounted as /dev/sda)
sudo dd if=/dev/zero of=/dev/sda bs=16M

Using fdisk to create the partitions:
sudo fdisk /dev/sda

Don't worry with the filesystem yet, just try to run rpi-clone.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

ok done that:
Device Boot Start End Sectors Size Id Type
/dev/sda1 2048 526335 524288 256M c W95 FAT32 (LBA)
/dev/sda2 526336 62924799 62398464 29,8G 83 Linux

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

Nice, test the rpi-clone now.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

bad news:
sudo rpi-clone sda

Booted disk: mmcblk0 8.0GB Destination disk: sda 32.2GB

Part Size FS Label Part Size FS Label
1 /boot 256.0M fat32 -- 1 256.0M fat32 --
2 root 7.2G ext4 rpidmtcz 2 29.8G ext4 rpidmtcz

== SYNC mmcblk0 file systems to sda ==
/boot (47.5M used) : SYNC to sda1 (256.0M size)
/ (1.8G used) : SYNC to sda2 (29.8G size)

Run setup script : no.

Verbose mode : no.

Ok to proceed with the clone? (yes/no): y

Syncing file systems (can take a long time)
Syncing mounted partitions:
Mounting /dev/sda2 on /mnt/clone
=> rsync // /mnt/clone with-root-excludes ...rsync: recv_generator: mkdir "/mnt/clone/var" failed: Bad message (74)
*** Skipping any contents from this failed directory ***
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1207) [sender=3.1.3]

mkdir: impossible de créer le répertoire « /mnt/clone/boot »: Message invalide
Mounting /dev/sda1 on /mnt/clone/boot
mount: /mnt/clone/boot: cannot mount; probably corrupted filesystem on /dev/sda1.
Mount failure of /dev/sda1 on /mnt/clone/boot.
unmounting /mnt/clone
Aborting!

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

sorry for weird formated text

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

The SD card you are trying to clone, what OS do you have installed?

It is possible to manually create the boot partition, and then you just rsync the second partition (sda2).

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

It's a standard raspbian, for a domoticz server.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

on a RPI 3B

from rpi-clone.

framps avatar framps commented on September 27, 2024

I did'nt check logs before today, shame on me !

Why don't you create a small wrapper script which calls rpi-clone and sends a failure eMail to you if rpi-clone fails 😉

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

Hi framps. Good idea !

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

But first I'd like to fix rpi-clone. Any Idea ?

from rpi-clone.

viniciuspaes avatar viniciuspaes commented on September 27, 2024

Do you have another external drive available? So we can isolate the problem.

from rpi-clone.

Philtass avatar Philtass commented on September 27, 2024

I try with another SD card with only one partition. rpi-clone creates the 2 partitions and continues... for the moment

from rpi-clone.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.