Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux? |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
05-22-2023, 10:10 AM
|
#1
|
LQ Guru
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342
|
how to recover a 16 or 32GB usb stick
I was burning an iso to a usb stick and got frustrated because dd would not complete the copy and opened gparted then just told it to format it to msdos 16 whatever and ended up with a 8 mb stick but when I plug it in thunar opens three partitions under /run/media/
/run/media/userx/039E-EF17/efi free space 43kib
/run/media/userx/Bodhi Live CD/ freespace 0 bytes (zero)
/run/media/userx/writable/ freespace 27.0 GiB
that last one has a crash log dir
gparted is just showing the used part of like 8MB
Code:
Disk: /dev/sdb
Size: 8 MiB, 8388608 bytes, 16384 sectors
Label: gpt, identifier: 75BC8DE0-5780-4D2E-8257-1ED47E61A861
Device Start End Sectors Size Type
>> /dev/sdb1 2048 14335 12288 6M Linux filesystem
Code:
# fdisk -l /dev/sdb
Disk /dev/sdb: 8 MiB, 8388608 bytes, 16384 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 75BC8DE0-5780-4D2E-8257-1ED47E61A861
Device Start End Sectors Size Type
/dev/sdb1 2048 14335 12288 6M Linux filesystem
I don't know what else to post
Last edited by BW-userx; 05-22-2023 at 10:23 AM.
|
|
|
05-22-2023, 10:20 AM
|
#2
|
Senior Member
Registered: Jul 2018
Location: Silicon Valley
Distribution: Bodhi Linux
Posts: 1,516
|
gparted has an option under device to "create partition table".
|
|
|
05-22-2023, 10:26 AM
|
#3
|
LQ Guru
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342
Original Poster
|
Quote:
Originally Posted by enigma9o7
gparted has an option under device to "create partition table".
|
I tried that but it is only giving me a 8mb size and not recovering the amount of the usb stick
Last edited by BW-userx; 05-22-2023 at 10:29 AM.
|
|
|
05-22-2023, 10:41 AM
|
#4
|
LQ Guru
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342
Original Poster
|
Quote:
Originally Posted by enigma9o7
gparted has an option under device to "create partition table".
|
Okay I got it back somehow after booting the usb stick into bodhi and it failed to run its install then booted into slack and opened gparted then seen it all so I wiped it then created a new partition table regaining the 32GB
|
|
|
05-22-2023, 01:39 PM
|
#5
|
LQ Guru
Registered: Aug 2016
Location: SE USA
Distribution: openSUSE 24/7; Debian, Knoppix, Mageia, Fedora, OS/2, others
Posts: 6,496
|
Quote:
Originally Posted by BW-userx
I was burning an iso to a usb stick and got frustrated because dd would not complete the copy and opened gparted then just told it to format it to msdos 16 whatever and ended up with a 8 mb stick but when I plug it in thunar opens three partitions under /run/media/
|
When you change partitioning on a USB device, it helps with some tools to run partprobe immediately after completion, but basically it needs to be safely removed then reinserted if you want everything, including kernel, to work right WRT to that device's content.
Save yourself some grief and use ddrescue instead of dd. It provides status by default, so that you know when it actually gets done. Just because dd appears to complete doesn't mean the write process is complete - there can be a considerable amount remaining to be written, leaving you with a corrupted device needing the whole process started from scratch if you attempt to take action with or upon it before writing completes.
|
|
2 members found this post helpful.
|
All times are GMT -5. The time now is 08:50 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|