Supporting ZSUN Wifi Card Reader (16MB Flash, 64MB RAM, AR9331)

getting permission denied on that one, I assume you meant it with a sudo prefix?

That is usually because the user permission of docker program, you should have got the note when you install it.

If you would like to use Docker as a non-root user, you should now consider
adding your user to the "docker" group with something like:
  sudo usermod -aG docker your-user
Remember that you will have to log out and back in for this to take effect!
WARNING: Adding a user to the "docker" group will grant the ability to run
         containers which can be used to obtain root privileges on the
         docker host.
         Refer to https://docs.docker.com/engine/security/security/#docker-daemon-attack-surface
         for more information.

Sudo may works, or run it as root also. For more details check official document.

I wonder if its the thing with docker that causes me not to build correctly... after quite some time I get:

make[2] checksum
rm: cannot remove 'build_dir/host/tar-1.30/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3/confdir3
...
 File name too long

rm: cannot remove 'build_dir/host/findutils-4.6.0/confdir3/confdir3/confdir3/confd...
 File name too long

The command '/bin/sh -c make -j"$(nproc)" FORCE_UNSAFE_CONFIGURE=1 &&     rm -rf build_dir' returned a non-zero code: 1

I will make the changes and see if I get the same result...

Nah, same result even when docker is not complaining about permissions.

It seems to happen by old storage driver. I made a test build under aufs and got the same error.

Can you check your storage driver by docker info? I guess maybe you are using old docker version or Linux kernel doesn't support overlay2, so it uses aufs.

Test on Ubuntu 16 and 18, Centos7 with latest docker are passed.

I'm running Ubuntu 18.04.2 LTS, the docker info output is:

docker info
Containers: 5
 Running: 0
 Paused: 0
 Stopped: 5
Images: 15
Server Version: 18.06.1-ce
Storage Driver: aufs
 Root Dir: /var/snap/docker/common/var-lib-docker/aufs
 Backing Filesystem: extfs
 Dirs: 23
 Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 468a545b9edcd5932818eb9de8e72413e616e86e
runc version: N/A (expected: 69663f0bd4b60df09991c08812a60108003fa340)
init version: 949e6fa (expected: fec3683)
Security Options:
 apparmor
 seccomp
  Profile: default
Kernel Version: 4.15.0-51-generic
Operating System: Ubuntu Core 16
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 15.55GiB
Name: henrik-ThinkPad-T450
ID: CI7B:XF5A:NE5I:BLEF:BNR3:EZVX:2O4E:K3BZ:TBJX:GVTG:JIGC:XIDA
Docker Root Dir: /var/snap/docker/common/var-lib-docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: 22
 Goroutines: 44
 System Time: 2019-06-17T16:48:02.595817304+02:00
 EventsListeners: 0
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

WARNING: No swap limit support

That's the problem, it should be overlay2.

aufs is the preferred storage driver for Docker 18.06 and older, when running on Ubuntu 14.04 on kernel 3.13 which has no support for overlay2.

You need update your docker program.

Everything is updated, I did change it to overlay2 however, and now it compiled without problems. Thanks.

Hmm, however, I cannot connect to my container and get the compiled images...
netstat -atn does not reveal any open ports on 80 or 8080.

Does docker ps -a show something?

I get
Step 15/15 : CMD python -m SimpleHTTPServer 80
---> Using cache
---> eebf6d410828
Successfully built eebf6d410828
Successfully tagged zsun:latest
and that command
docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
shows up empty...

I wonder if I did something wrong when going from aufs to overlay2... maybe should just redo it once more...

Did you execute docker run -d -p 8080:80 zsun ?

Im gonna go with yes, and then hide.
Thanks.

Did someone get the microsd to work in the lede images ?

My twin Zsuns are running ...

  _______                     ________        __
 |       |.-----.-----.-----.|  |  |  |.----.|  |_
 |   -   ||  _  |  -__|     ||  |  |  ||   _||   _|
 |_______||   __|_____|__|__||________||__|  |____|
          |__| W I R E L E S S   F R E E D O M
 -----------------------------------------------------
 OpenWrt 18.06.1, r7258-5eb055306f
 -----------------------------------------------------

... and this does not detect a ĀµSD card after a fresh install.

Trying to install kmod-usb-storage, I get:

root@zsun0:~# opkg install kmod-usb-storage
Installing kmod-usb-storage (4.9.120-1) to root...
Downloading http://downloads.openwrt.org/releases/18.06.1/targets/ar71xx/generic/packages/kmod-usb-storage_4.9.120-1_mips_24kc.ipk
Collected errors:
 * satisfy_dependencies_for: Cannot satisfy the following dependencies for kmod-usb-storage:
 *      kernel (= 4.9.120-1-adfb989aae12e239d65a2c73ca35b8a3) *         kernel (= 4.9.120-1-adfb989aae12e239d65a2c73ca35b8a3) *       kernel (= 4.9.120-1-adfb989aae12e239d65a2c73ca35b8a3) *         kernel (= 4.9.120-1-adfb989aae12e239d65a2c73ca35b8a3) * 
 * opkg_install_cmd: Cannot install package kmod-usb-storage.

Kernel vs modules mismatch?

I remember to have extrooted my Zsuns in Chaos-Calmer days and to have used the card readers under LEDE-17 but I haven't kept up with the updates/upgrade since then and both run a fairly unconfigured OpenWrt-18.06.1 now.

Did I miss an update/upgrade?

1 Like

If you compile the image you need to use the kmod-usb-storage with the compiled image.

I did that but still the card was not detected, so was wondering if something else is missing

Hi, could you post a short description, how you got 18.06 on your Zsun? I checked the github repo a few posts up, but it references lede17.01 as install source. Thanks :slight_smile:
I'm asking, because i remember reading about a way to make an "sdcard" update, so without having to solder the ultra-tiny serial and the ethernet jack.
Or did you "sysupgrade up from Lede17.01 to OW18.06"?

See my small summary at Supporting ZSUN Wifi Card Reader (16MB Flash, 64MB RAM, AR9331) and(!) the message(s) of @puteulanus above it.

I'm running the version without the rescue system (https://github.com/puteulanus/zsun-builder/releases/tag/v0.3) so there is already a newer variant with wireless rescue system (https://github.com/puteulanus/zsun-builder/releases/tag/v0.6) and somewhere in this thread are instructions how to install that release too.

1 Like

Thanks for your work! Are you planning to integrate the patches to the main repo?

1 Like

Devs are categorically against that. Read the beginning of the thread.

1 Like