Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
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.
|
|
|
01-24-2017, 10:13 PM
|
#16
|
Senior Member
Registered: Dec 2009
Location: New Jersey, USA
Distribution: Fedora, OpenSUSE, FreeBSD, OpenBSD, macOS (hack). Past: Debian, Arch, RedHat (pre-RHEL).
Posts: 1,335
|
Code:
dd if=Desktop/kali-linux-2016.2-amd64.iso of=/dev/sdb bs=512k
should work in your case, from that output.
|
|
|
01-25-2017, 07:41 AM
|
#17
|
Member
Registered: Nov 2012
Posts: 300
Rep:
|
From the output of that dmesg it shows that your USB drive has been detected and it is 16GB like you said, and it is sdb. It doesn't really matter about what was output with dmesg -c, that was just to clear the old data so you knew the only messages shown were to do with you plugging in the USB device.
With sdb being detected, as shown by dmesg then your command should work
Code:
dd if=Desktop/kali-linux-2016.2-amd64.iso of=/dev/sdb bs=512k
Make sure you are in the right directory so that the iso file can be found, or put the full path to it on the if option, eg:
Code:
dd if=/home/user/Desktop/kali-linux-2016.2-amd64.iso of=/dev/sdb bs=512k
|
|
|
01-25-2017, 10:14 AM
|
#18
|
LQ Newbie
Registered: Jan 2017
Posts: 23
Original Poster
Rep:
|
Quote:
Originally Posted by goumba
Code:
dd if=Desktop/kali-linux-2016.2-amd64.iso of=/dev/sdb bs=512k
should work in your case, from that output.
|
Nope, I still get the same error. What do I do now?
|
|
|
01-25-2017, 10:15 AM
|
#19
|
LQ Newbie
Registered: Jan 2017
Posts: 23
Original Poster
Rep:
|
Quote:
Originally Posted by af7567
From the output of that dmesg it shows that your USB drive has been detected and it is 16GB like you said, and it is sdb. It doesn't really matter about what was output with dmesg -c, that was just to clear the old data so you knew the only messages shown were to do with you plugging in the USB device.
With sdb being detected, as shown by dmesg then your command should work
Code:
dd if=Desktop/kali-linux-2016.2-amd64.iso of=/dev/sdb bs=512k
Make sure you are in the right directory so that the iso file can be found, or put the full path to it on the if option, eg:
Code:
dd if=/home/user/Desktop/kali-linux-2016.2-amd64.iso of=/dev/sdb bs=512k
|
I tried that, and and it still didnt work. I got the exact same error.
|
|
|
01-25-2017, 10:54 AM
|
#20
|
LQ Guru
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573
|
Are you sure the drive is good?
Could you post the output of fdisk -l now that the drive is being recognized?
|
|
|
01-25-2017, 11:22 AM
|
#21
|
LQ Newbie
Registered: Jan 2017
Posts: 23
Original Poster
Rep:
|
Quote:
Originally Posted by suicidaleggroll
Are you sure the drive is good?
Could you post the output of fdisk -l now that the drive is being recognized?
|
Im 100% certain the drive is good. I got it from best buy the same day I tried to make it bootable.
This is what the output came back to
Code:
Disk /dev/sda: 40 GiB, 42949672960 bytes, 83886080 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: dos
Disk identifier: 0xbecf30ae
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 79691775 79689728 38G 83 Linux
/dev/sda2 79693822 83884031 4190210 2G 5 Extended
/dev/sda5 79693824 83884031 4190208 2G 82 Linux swap / Solaris
|
|
|
01-25-2017, 12:27 PM
|
#22
|
Member
Registered: Nov 2012
Posts: 300
Rep:
|
fdisk -l might not show /dev/sdb because it doesn't have a partition table (dmesg showed that it has no partitions).
What does the ls command show you
With the USB plugged in I would expect something like
Code:
brw-rw---- 1 root disk 8, 0 Jan 25 11:45 /dev/sda
brw-rw---- 1 root disk 8, 1 Jan 25 11:45 /dev/sda1
brw-rw---- 1 root disk 8, 2 Jan 25 11:45 /dev/sda2
brw-rw---- 1 root disk 8, 4 Jan 25 11:45 /dev/sda5
brw-rw---- 1 root disk 8, 16 Jan 25 11:45 /dev/sdb
|
|
|
01-25-2017, 12:31 PM
|
#23
|
LQ Newbie
Registered: Jan 2017
Posts: 23
Original Poster
Rep:
|
Quote:
Originally Posted by af7567
fdisk -l might not show /dev/sdb because it doesn't have a partition table (dmesg showed that it has no partitions).
What does the ls command show you
With the USB plugged in I would expect something like
Code:
brw-rw---- 1 root disk 8, 0 Jan 25 11:45 /dev/sda
brw-rw---- 1 root disk 8, 1 Jan 25 11:45 /dev/sda1
brw-rw---- 1 root disk 8, 2 Jan 25 11:45 /dev/sda2
brw-rw---- 1 root disk 8, 4 Jan 25 11:45 /dev/sda5
brw-rw---- 1 root disk 8, 16 Jan 25 11:45 /dev/sdb
|
This was the output:
Code:
brw-rw---- 1 root disk 8, 0 Jan 25 12:29 /dev/sda
brw-rw---- 1 root disk 8, 1 Jan 25 12:29 /dev/sda1
brw-rw---- 1 root disk 8, 2 Jan 25 12:29 /dev/sda2
brw-rw---- 1 root disk 8, 5 Jan 25 12:29 /dev/sda5
The USB was plugged in
|
|
|
01-25-2017, 12:36 PM
|
#24
|
Member
Registered: Nov 2012
Posts: 300
Rep:
|
Something is broken somewhere. Your dmesg output showed that the USB was definitely plugged in and was /dev/sdb, but /dev/sdb doesn't exist. If you check dmesg output again do you see anything saying about USB disconnected (even though it is still plugged in)? If you plug it in then immediately check "ls -l /dev/sd*" is it shown then? It could be a bad connection on the USB port.
|
|
|
01-25-2017, 12:54 PM
|
#25
|
Senior Member
Registered: Dec 2009
Location: New Jersey, USA
Distribution: Fedora, OpenSUSE, FreeBSD, OpenBSD, macOS (hack). Past: Debian, Arch, RedHat (pre-RHEL).
Posts: 1,335
|
Quote:
Originally Posted by af7567
fdisk -l might not show /dev/sdb because it doesn't have a partition table (dmesg showed that it has no partitions).
|
While it has no partitions, fdisk would still show the size of the device itself.
Last edited by goumba; 01-25-2017 at 12:55 PM.
|
|
|
01-25-2017, 01:03 PM
|
#26
|
LQ Newbie
Registered: Jan 2017
Posts: 23
Original Poster
Rep:
|
Quote:
Originally Posted by af7567
Something is broken somewhere. Your dmesg output showed that the USB was definitely plugged in and was /dev/sdb, but /dev/sdb doesn't exist. If you check dmesg output again do you see anything saying about USB disconnected (even though it is still plugged in)? If you plug it in then immediately check "ls -l /dev/sd*" is it shown then? It could be a bad connection on the USB port.
|
No, nothing shows that its disconnected.
I quickly took out the usb then plugged it back in and ran the 1s -1 /dev/sd*. It actually showed up. This was the output:
Code:
brw-rw---- 1 root disk 8, 0 Jan 25 12:53 /dev/sda
brw-rw---- 1 root disk 8, 1 Jan 25 12:53 /dev/sda1
brw-rw---- 1 root disk 8, 2 Jan 25 12:53 /dev/sda2
brw-rw---- 1 root disk 8, 5 Jan 25 12:53 /dev/sda5
brw-rw---- 1 root disk 8, 16 Jan 25 12:56 /dev/sdb
and if it is bad connection, do I just change ports?
|
|
|
01-25-2017, 01:05 PM
|
#27
|
LQ Guru
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573
|
goumba is correct, fdisk will still show the device information even if there is no partition table, the partition table is corrupt, etc.
Are you pressing an eject button or similar in your system? Some distros will actually eject the drive completely when you do that, so the only way for it to be recognized again is to unplug/replug it. Or is there anything else you're doing to the drive between plugging it in, showing us the dmesg output, running dd, and then running fdisk?
Maybe try unplugging it, plugging it back in, and then running fdisk -l. An I/O error during the dd dump might be causing the drive to disconnect itself.
Also - purchasing it new is absolutely no guarantee that it's good. Drives come DOA all the time.
|
|
1 members found this post helpful.
|
01-25-2017, 01:36 PM
|
#28
|
LQ Newbie
Registered: Jan 2017
Posts: 23
Original Poster
Rep:
|
Quote:
Originally Posted by suicidaleggroll
goumba is correct, fdisk will still show the device information even if there is no partition table, the partition table is corrupt, etc.
Are you pressing an eject button or similar in your system? Some distros will actually eject the drive completely when you do that, so the only way for it to be recognized again is to unplug/replug it. Or is there anything else you're doing to the drive between plugging it in, showing us the dmesg output, running dd, and then running fdisk?
Maybe try unplugging it, plugging it back in, and then running fdisk -l. An I/O error during the dd dump might be causing the drive to disconnect itself.
Also - purchasing it new is absolutely no guarantee that it's good. Drives come DOA all the time.
|
Thank you so much! I think I just figured it out. It wasnt reading it at first, so I quickly pulled it out and plugged it in. I ran the dd command again and it worked! I think it worked because whatever was stopping kali from reading the USB didnt have time to make that error.
|
|
|
All times are GMT -5. The time now is 03:11 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
|
|