Xiaomi 3g problem with installation

So i have problem with installing openwrt on my device
When i try open the sda1 i have communique

premission denied

BusyBox v1.19.4 (2017-08-25 14:56:06 CST) built-in shell (ash)
Enter 'help' for a list of built-in commands.

 -----------------------------------------------------
       Welcome to XiaoQiang!
 -----------------------------------------------------
  $$$$$$\  $$$$$$$\  $$$$$$$$\      $$\      $$\        $$$$$$\  $$\   $$\
 $$  __$$\ $$  __$$\ $$  _____|     $$ |     $$ |      $$  __$$\ $$ | $$  |
 $$ /  $$ |$$ |  $$ |$$ |           $$ |     $$ |      $$ /  $$ |$$ |$$  /
 $$$$$$$$ |$$$$$$$  |$$$$$\         $$ |     $$ |      $$ |  $$ |$$$$$  /
 $$  __$$ |$$  __$$< $$  __|        $$ |     $$ |      $$ |  $$ |$$  $$<
 $$ |  $$ |$$ |  $$ |$$ |           $$ |     $$ |      $$ |  $$ |$$ |\$$\
 $$ |  $$ |$$ |  $$ |$$$$$$$$\       $$$$$$$$$  |       $$$$$$  |$$ | \$$\
 \__|  \__|\__|  \__|\________|      \_________/        \______/ \__|  \__|


root@XiaoQiang:~# df -h
Filesystem                Size      Used Available Use% Mounted on
rootfs                   18.8M     18.8M         0 100% /
none                    122.9M         0    122.9M   0% /dev
tmpfs                   123.6M      3.7M    119.9M   3% /tmp
/dev/mtdblock13          18.8M     18.8M         0 100% /
tmpfs                   123.6M      3.7M    119.9M   3% /tmp
tmpfs                   123.6M      3.7M    119.9M   3% /extdisks
ubi1_0                   43.5M      6.8M     34.4M  16% /data
ubi1_0                   43.5M      6.8M     34.4M  16% /userdisk
/dev/mtdblock13          18.8M     18.8M         0 100% /userdisk/data
ubi1_0                   43.5M      6.8M     34.4M  16% /etc
/dev/sda1                28.9G      5.8M     28.9G   0% /extdisks/sda1
root@XiaoQiang:~# /extdisks/sda1
-ash: /extdisks/sda1: Permission denied
root@XiaoQiang:~# /etc/
-ash: /etc/: Permission denied
root@XiaoQiang:~# /tmp
-ash: /tmp: Permission denied

Try it like this cd /extdisks/sda1; ls -la
And please edit your post to use preformatted text </>
Use it whenever you post output from device.

2 Likes

You are trying to "run" folders. You can't "run" folder, you can only make it working with command "cd". Try following commands and see output:

pwd
cd /tmp
pwd
ls
mount

Output of last command gives you folder, where USB is accessible.

1 Like
root@XiaoQiang:~# cd /extdisks/sda1; ls -la
drwxrwxrwx    1 root     root         16384 Jan  1  1970 .
drwxr-xr-x    3 root     root            60 Aug 25 23:11 ..
drwxrwxrwx    1 root     root         16384 Aug 25 23:11 .systemconfig
drwxrwxrwx    1 root     root         16384 Dec  9  2019 System Volume Information
drwxrwxrwx    1 root     root         16384 Aug 25 23:12 TDDOWNLOAD
drwxrwxrwx    1 root     root         16384 Aug 25 23:13 ThunderDB
-rwxrwxrwx    1 root     root       1839081 Dec  9  2019 a1.bin
-rwxrwxrwx    1 root     root       3538944 Dec  9  2019 a2.bin
-rwxrwxrwx    1 root     root          4464 Dec  7  2019 miwifi_ssh.bin
drwxrwxrwx    1 root     root         16384 Aug 25 23:11 xiaomi_config
drwxrwxrwx    1 root     root         16384 Aug 25 23:11 ??
drwxrwxrwx    1 root     root         16384 Aug 25 23:11 ??
root@XiaoQiang:/extdisks/sda1# mtd write a1.bin karnel1
Could not open mtd device: karnel1
Can't open device for writing!

and second

root@XiaoQiang:~# pwd
/root
root@XiaoQiang:~# cd /tmp
root@XiaoQiang:/tmp# pwd
/tmp
root@XiaoQiang:/tmp# ls
4636.bootcheck.log          lock                        rc.timing                   syslog-ng.ctl
DataBase                    locks                       resolv.conf                 syslog-ng.pid
TZ                          log                         resolv.conf.auto            taskmonitor
apk_query.pid               logexec                     rr                          thunder
arrays                      luci-indexcache             run                         uci2dat_mt7603e.log
cache                       luci-modulecache            security.db                 uci2dat_mt7612.log
daemon                      messages                    spool                       uploadfiles
dhcp.leases                 mihttpd                     startscene_crontab.lua.PID  upnp.leases
etc                         mnt                         stat_points_privacy.log     web_config_list
etm.log                     mt76xx.sh.log               stat_points_rom.log         web_filter_list
fstab                       network.env                 state                       wifi_analysis.log
hosts                       nginx_check.log             sysapihttpd
http_info                   oui                         sysapihttpdconf
kr_query.pid                rc.done                     sysinfo
root@XiaoQiang:/tmp# mount
rootfs on / type rootfs (rw)
none on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
none on /proc type proc (rw,nosuid,nodev,noexec,relatime)
none on /dev type devtmpfs (rw,relatime,size=125812k,nr_inodes=31453,mode=755)
tmpfs on /tmp type tmpfs (rw,nosuid,relatime,size=227812k,mode=755)
/dev/mtdblock13 on / type squashfs (ro,relatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,relatime,size=126564k)
devpts on /dev/pts type devpts (rw,relatime,mode=600)
tmpfs on /extdisks type tmpfs (rw,nosuid,nodev,relatime,size=126564k)
ubi1_0 on /data type ubifs (rw,relatime)
ubi1_0 on /userdisk type ubifs (rw,relatime)
/dev/mtdblock13 on /userdisk/data type squashfs (ro,relatime)
ubi1_0 on /etc type ubifs (rw,relatime)
none on /dev/cgroup/mem type cgroup (rw,relatime,memory)
/dev/sda1 on /extdisks/sda1 type tfat (rw,noatime,uid=0,gid=0,umask=0000,allow_utime=0022,codepage=437,iocharset=utf8,shortname=winnt,min_prealloc_size=64k,max_prealloc_size=29596k,readahead=1M,fail_safe,hidden=show,errors=continue)

You don't need to copy paste on the device every command you see.

Other than that I don't see where the problem is with your device.

1 Like

I just want install openwrt on my device and i don't understad why i can't
I'am noob in this i use instructions ssh from page about of xiaomi 3g openwrt and it didn't work
When i try i have always this output

Permission denied

When i use your command i think i have access to folder with file next i use this

mtd write a1.bin karnel1

and give me this

Could not open mtd device: karnel1
Can't open device for writing!

and i don't understad why i can't

sorry but my english is very low and i can misuderstand you

@pttp13k, welcome to the community!

I surmise the main problem is because you misspelled the word "kernel". I don't want to give more details, because I honestly think you're unsure of what you're doing...which leads me to ask - are you following the instructions here: https://openwrt.org/toh/xiaomi/mir3g#installation ?

3 Likes

you have right i write wrong kernel1 i feel so stupid right now but thanks

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.