Locating the /dev entry to make partitions on an SD card

15,807

Solution 1

The SD card is not necessary visible as /dev/mmcblk*. Another possibility is /dev/sd*.

You can find name the either by looking into the dmesg output. Other way is to eject card, type ls /dev, insert card, do ls /dev again and find the difference.

Solution 2

Try on the command line in konsole:

lsblk

which should list all of your hard drives and their partitions.

Share:
15,807

Related videos on Youtube

tabish
Author by

tabish

Updated on September 18, 2022

Comments

  • tabish
    tabish over 1 year

    I am trying to create partition of SD card, for this I am following this tutorial. When I type the command

    ll /dev/mmcblk*
    

    I got this

    ls: cannot access /dev/mmcblk*: No such file or directory
    

    So, I check the list of items in /dev by typing this command

    ls /dev/
    

    I got a big list of items but there is nothing like mmcblk0 or mmcblk1. The list I am getting is this

    autofs           dvdrw     loop4               psaux  ram6    sdb       tty10  tty24  tty38  tty51  tty8       ttyS2   ttyS5    vcs6
    block            ecryptfs  loop5               ptmx   ram7    sdb1      tty11  tty25  tty39  tty52  tty9       ttyS20  ttyS6    vcs7
    bsg              fb0       loop6               pts    ram8    sg0       tty12  tty26  tty4   tty53  ttyprintk  ttyS21  ttyS7    vcsa
    btrfs-control    fd        loop7               ram0   ram9    sg1       tty13  tty27  tty40  tty54  ttyS0      ttyS22  ttyS8    vcsa1
    bus              full      loop-control        ram1   random  sg2       tty14  tty28  tty41  tty55  ttyS1      ttyS23  ttyS9    vcsa2
    cdrom            fuse      mapper              ram10  rfkill  shm       tty15  tty29  tty42  tty56  ttyS10     ttyS24  uhid     vcsa3
    cdrw             hidraw0   mcelog              ram11  rtc     snapshot  tty16  tty3   tty43  tty57  ttyS11     ttyS25  uinput   vcsa4
    char             hpet      mei                 ram12  rtc0    snd       tty17  tty30  tty44  tty58  ttyS12     ttyS26  urandom  vcsa5
    console          input     mem                 ram13  sda     sr0       tty18  tty31  tty45  tty59  ttyS13     ttyS27  v4l      vcsa6
    core             kmsg      net                 ram14  sda1    stderr    tty19  tty32  tty46  tty6   ttyS14     ttyS28  vcs      vcsa7
    cpu              log       network_latency     ram15  sda2    stdin     tty2   tty33  tty47  tty60  ttyS15     ttyS29  vcs1     vga_arbiter
    cpu_dma_latency  loop0     network_throughput  ram2   sda3    stdout    tty20  tty34  tty48  tty61  ttyS16     ttyS3   vcs2     vhost-net
    disk             loop1     null                ram3   sda4    tty       tty21  tty35  tty49  tty62  ttyS17     ttyS30  vcs3     video0
    dri              loop2     port                ram4   sda5    tty0      tty22  tty36  tty5   tty63  ttyS18     ttyS31  vcs4     zero
    dvd              loop3     ppp                 ram5   sda6    tty1      tty23  tty37  tty50  tty7   ttyS19     ttyS4   vcs5
    

    I have followed this tutorial before but I do not any idea what's wrong this time. So,please tell how to get mmcblk list.

    • Matej Vrzala M4
      Matej Vrzala M4 almost 10 years
      Can you check to see if the SD card is mounted? If you are trying to partition it, it cannot be mounted.
    • tabish
      tabish almost 10 years
      I am newbie, I dont know how to check, please tell me command for this
    • Matej Vrzala M4
      Matej Vrzala M4 almost 10 years
      try this: df | grep -q partition
    • tabish
      tabish almost 10 years
      @garethTheRed:- there is a change in last line, when sd card is not inserted, there is one extra line:- [ 3087.215682] usb 2-1.6: USB disconnect, device number 6
    • tabish
      tabish almost 10 years
      @ryekayo:- df | grep -q partition make no difference
    • garethTheRed
      garethTheRed almost 10 years
      Insert the SD Card and run dmesg again. See what info you get. Also note what @gena2x said. You have a sdb in your /dev. Is that the SD Card?
    • tabish
      tabish almost 10 years
      I tried one more time, this when I remove SD card, I got this line in end:- [ 3645.182867] sdb: detected capacity change from 15976103936 to 0 so, sdb1 is my sd card name?
    • tabish
      tabish almost 10 years
      I tried Gena instruction, that is I tried ls /dev with and without sd Card , the only difference is is sdb1 is extra there
  • tabish
    tabish almost 10 years
    /dev/sd* command showing this error sudo: /dev/sda: command not found
  • Gilles 'SO- stop being evil'
    Gilles 'SO- stop being evil' almost 10 years
    @tabish /dev/sd* isn't a command, it's a pattern that might match some files. RUn echo /dev/sd* or ls -l /dev/sd*.