GLiNet MT1300 - OpenWRT mobile router





I purchased one of these as I am living in temporary accommodation and sharing an internet connection with other people in building. The idea was to connect this to the internet router (virgin medias next door) via wireless and create a new wireless network for my use.
I purchased the GL-MT1300 on amazon and have been amazed at what it can do in such a small format. I have added a 32GB micro SD card and also use it with a USB 4TB Seagate mobile drive.
Here is some of the configuration I used.

Base build out

Power up the device and connect to the default SSID with pascode:goodwill
connect to the web interface on 192.168.8.1
set password

{If doing restore: ssh in to device and restore fstab settings for overlay, or restore mtdblock6}

This is all first time only, if this is a restore just mount the new overlay:
Setup wireless for your SSID
connect to internet (WAN) use 5G if available
configure LANIP
configure manual DNS
install mc {I use this tool a lot}
run mc, change display bits to ISO8559-1 change putty to same {This is so the borders show correctly}
install Luci {You can do this by going to the advance page in the web interface}
connect to Luci, do backup {Might as well have an initial backup}

At this point the unit was already working great but there are so many features to explore things to break play with.

extroot

Got most of the config needed from this page
https://openwrt.org/docs/guide-user/additional-software/extroot_configuration


{note to self! Don't delete contents of old overlay or it will reboot to factory!}

connect to device using ssh
opkg install block-mount kmod-fs-ext4 kmod-usb-storage kmod-usb-ohci kmod-usb-uhci e2fsprogs fdisk
use fdisk to delete old partitions, create a 1GB primary and use rest as 2nd part.


configure the SD card:
DEVICE="/dev/mmcblk0p1"
mkfs.ext4 ${DEVICE}


This configures the old root_data to be under /rwm so its accessable, it edits /etc/config/fstab:
DEVICE="$(sed -n -e "/\s\/overlay\s.*$/s///p" /etc/mtab)"
uci -q delete fstab.rwm
uci set fstab.rwm="mount"
uci set fstab.rwm.device="${DEVICE}"
uci set fstab.rwm.target="/rwm"
uci commit fstab


configure fstab:
DEVICE="/dev/mmcblk0p1"
eval $(block info ${DEVICE} | grep -o -e "UUID=\S*")
uci -q delete fstab.overlay
uci set fstab.overlay="mount"
uci set fstab.overlay.uuid="${UUID}"
uci set fstab.overlay.target="/overlay"
uci commit fstab


transfer test and reboot:
mkdir -p /tmp/cproot
mount --bind /overlay /tmp/cproot
mount ${DEVICE} /mnt
tar -C /tmp/cproot -cvf - . | tar -C /mnt -xf -
umount /tmp/cproot /mnt
reboot


backup /mnt/usb is a drive that can be use, thumb drive for example
Old unit: tar -cvzf /mnt/usb/overlay.tar.gz /overlay
Copy the tar file from old to new unit <- move the thumb drive and mount
New unit: cd /; tar -xvzf /mnt/usb/overlay.tar.gz


script to reset USB device after boot
#port="1-1.1" # as shown by lsusb -t: {bus}-{port}(.{subport})
echo "2-1" >/sys/bus/usb/drivers/usb/unbind
sleep 1

echo "2-1" >/sys/bus/usb/drivers/usb/bind

USB drive

install 
block-mount {might of done in samba}
e2fsprogs
usbutils
luci-app-hd-idle


edit /etc/modules.d/usb-storage
usb-storage quirks=0x0bc2:0x2344:u


configure share for /mnt/sda2
configure idle timeout for sda {via luci hd idle}


after boot: <-need to fix this post boot
<- possibly fixed in /etc/rc.local
/etc/init.d/led stop {this turns off the LED, nice at night as its in same room as my bed}


mount /dev/sda2 /mnt/sda2


#port="1-1.1" # as shown by lsusb -t: {bus}-{port}(.{subport})


echo "2-1" >/sys/bus/usb/drivers/usb/unbind
sleep 1
echo "2-1" >/sys/bus/usb/drivers/usb/bind

Samba 4

Dont install the default samba stuff, if it is remove it! You might also need to do extroot before hand so there is room for the slightly larger packages.

delete /etc/samba/smb.conf.template
delete /etc/config/samba /etc/config/samba-opkg

install these packages in Luci:
shadow-useradd
block-mount
libext2fs2
mount-utils
fdisk
luci-app-samba4 <-installs server and libs
samba4-admin
samba4-client
samba4-utils


SSH:
useradd dstote
smbpasswd -a dstote


Luci:
setup samba defaults
setup share

Backup!!!

2 comments:

  1. Its organizers victoria secret panties didn't steer the selected young engineers and scientists into explicit fields. Instead, they let them pursue any sort of graduate studies in any Western nation. After completing his master's diploma in 1955, Ziv returned to the protection world, this time joining Israel's National Defense Research Laboratory to develop digital elements for use in missiles and different military techniques.

    ReplyDelete
  2. For instance, 4-axis CNC milling machines can rotate on the A-axis while 5-axis can rotate on the A and C axes or B and C axes. The vertical Pencil Sharpeners milling machine is a 3-axis machine with the desk and arm linked to a vertical column, and the spindle is vertical. A complex product design requires a machine that can effectively mill the product. The greater the complexity, the higher the milling machine’s sophistication, and the higher the cost. Operating Temperature.The materials melting temperature should be under the operating temperature of the CNC milling machine.

    ReplyDelete