RACHEL-Kolibri on Linux Mint

Hi Andrew,

The main page of RACHEL parses the output of an ifconfig command to show the lan/wifi interface’s assigned IP addresses, so that is correct. DHCP addresses are all set in the 10.10.10.100 - 10.10.10.199 range in the dnsmasq.conf file used as part of the RACHEL install. The wifi adapter has an ip of 10.42.0.1 because it’s being set by Network Manager and because the static ip setting from our dhcpcd file is being ignored by it. The reason the network is working is anything on the network is being forwarded through the iptables rules to “anywhere”.

So the only thing to do is figure out how to override Network Manager and set the IP to 10.10.10.10 for the wifi interface. This could be editable in the ipv4 settings menu for the hotspot connection like from above. If not, you can try /etc/network/interfaces and see if the 10.42.0.1 IP is set there and change it to 10.10.10.10.

When this is all figured out you should definitely do another fresh install with an updated installer to make sure it’s all working.

James

Hi James

I have not found anything in the GUI Network Connections interface yet that displays and allows me to change that IP.

interfaces currently reads as follows:-

interfaces(5) file used by ifup(8) and ifdown(8)

auto lo
iface lo inet loopback

So the 10.42.0.1 must be held somewhere else.
I can try ADDing that IP in the IP4 Settings tab and see what happens.

UPDATE That worked! And it still routes through to internet.
user1@rachel:~$ ifconfig
enp0s25: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.1.38 netmask 255.255.255.0 broadcast 192.168.1.255
inet6 fe80::2f99:3cb9:434:a830 prefixlen 64 scopeid 0x20
ether 68:f7:28:7a:34:2a txqueuelen 1000 (Ethernet)
RX packets 416 bytes 129907 (129.9 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 305 bytes 70517 (70.5 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device interrupt 20 memory 0xf0600000-f0620000

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 1000 (Local Loopback)
RX packets 354 bytes 125672 (125.6 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 354 bytes 125672 (125.6 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

wlp3s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 10.10.10.10 netmask 255.255.255.0 broadcast 10.10.10.255
inet6 fe80::5359:c2ec:621e:c9b prefixlen 64 scopeid 0x20
inet6 fe80::60ef:f222:4d9f:fc0 prefixlen 64 scopeid 0x20
ether cc:3d:82:4e:e9:cc txqueuelen 1000 (Ethernet)
RX packets 309 bytes 66361 (66.3 KB)
RX errors 0 dropped 1 overruns 0 frame 0
TX packets 385 bytes 249277 (249.2 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

user1@rachel:~$

We are there, I think.

Regards
Andrew

Hi Andrew,

Okay great. So to confirm, is everything working now? I’d like to look at automating more of this but it would take some testing.

James

One more thing I should mention. Versions are hardcoded right now in the RACHEL admin interface. The installed Kolibri version is likely 0.13.3, while the interface says 0.13.2. This is set in /etc/kolibri-version. You may want to change that for clarity. In the future I’d like all versioning to be automatic in the version page.

James

Hi James

I’m happy to continue testing it if you want to automate a bit more.

Would you be able to replicate in your install routine what I did in the Network Manager to set up the 10.10.10.10 IP for the hotspot?

What we probably ought to do also is retest it all from a clean install, including the change to make the hotspot persistent and make sure everything runs OK.

Let me now how you want to proceed.

UPDATE
Successfuly edited kolibri-version to reflect current version as 0.13.3. Needed root permissions.

Regards
Andrew

Hi Andrew,

I’m going to work on getting it all completely automated. I’m just clearing off a hard drive that I can use to boot Mint from and then go from there. These are the things I plan to do.

  1. Automatic interface naming in files to avoid having to hard code them. Currently if you run the installer on any other device it won’t work because of this. I also want that interface naming working before the iptables rules are set.

  2. Automated hotspot configuration. This is going to require me testing a lot. I need to test code that replaces network manager files and make sure they are set to default. This will include the 10.10.10.10 static ip setting.

  3. Changing Individual wifi settings like channel/SSID

  4. Changing DNS settings like the default web page for RACHEL

If you have any other suggestions let me know. I will probably have this ready in a few days but you never know with Network Manager haha.

James

Hi James

That’s fine. I don’t have any specific additions to your list for now but it seems enough for you to be going on with!

Regards
Andrew

James

On further thought…

  1. Is it possible to run the install script when Mint is installed? If so it would allow us to send out a USB stick with the MInt installation on it and follow on automatically with it installing RACHEL-Kolibri.

Also, after discussion with a colleague today:-

  1. Currently the X240s will be providing DHCP service. Could that be configurable as On or Off in the script as we have a few schools with servers/networks already and Cisco APs that we might send out to add later?
  2. For the RACHEL part of the system we will install at minimum Wikipedia and GCF LearnFree which are at least 9GB each. Our local partners in Malawi have limited internet bandwidth. Is it possible to get RACHEL to install modules from a local repository on HDD or another machine (in the same way that Kolibri can?

Regards
Andrew

Hi Andrew,

Sorry, I didn’t get a notification for this so I had assumed that last message was the last one and didn’t see this. Okay so lots of questions here to tackle.

  1. To run a completely offline install script would require a new installer. I would need to figure out every package that gets installed in the current process, download them and place them in a folder, then install them in a different way ( using dpkg ) in the script. This is possible, but it is really tough to be sure it will work in the field unless the mint installation is exactly the same as the one the installer was configured on. I will look at this though once the online installer is complete.

  2. I can definitely disable the dhcp setup. Does that mean they wouldn’t require any networking and would just require the other services? These kinds of things are easy to add to the script with options like --no-kiwix, --no-kolibri, --no-hotspot, --no-dhcp, which just tell the installer to skip those installation functions. Then the question “do you want to install dhcp?” can be asked in the GUI installer. I can also make a separate script/GUI for configuring a system any time after the initial installation to enable/disable all of these things easily. That way all of the functionality is there but the ability to turn it off is easy.

  3. There is an option that was removed for the RACHEL-Pi, which this is based off of, that can install from another rsync server in the RACHEL admin user interface’s install page. I can get this working for you. What you would need is an rsync server running on your local network that is configured the same way that the world possible’s server is with a json file listing the available modules. I could also look at writing a different utility that does this using another method. I’ll have to think about this a bit more though.

I have the predictive interface naming stuff done. I’m just working on getting the hotspot set up automatically and setting it as the default.

James

Hi James

Sorry, I didn’t get a notification for this

I am not getting any notifications at all from the forum no matter how I change the settings but I can’t seem to find a way to ask the Administrators to look at it. Can you?

To run a completely offline install script would require a new installer.
OK. Don’t bother. I will incorporate copying and running the installer into our instructions.

I can definitely disable the dhcp setup. Does that mean they wouldn’t require any networking and would just require the other services?
No, it just means that there may already be another DHCP server on the wired or wireless network. I guess to be precise we could need DHCP on either network. There are three scenarios I can envisage:-

  1. Schools has no existing network. DHCP server therefore required on both wired and wireless subnets.
  2. School has an existing wired network and DHCP server. DHCP required on WiFi only. X240 will get IP allocation over wired subnet from existing server.
  3. We add a Cisco wireless AP to the wired network from a donation we have had of several hundred of these. As they are more powerful we would probably make the Cisco the DHCP server for the WiFi (only).

So an option to ask the question on the X240 for each of the subnets would be fine. If it is not a server it needs to be a DHCP client to get an allocation of network details.

There is an option that was removed for the RACHEL-Pi, which this is based off of, that can install from another rsync server in the RACHEL admin user interface’s install page

We could probably have the RACHEL Master content on another laptop. I’m not sure how to set that up as an rsync server but I guess you could cover that? Ideally we would just have the required modules on an external HDD or memory stick - I have purchased 10 x 64GB SanDisk ones that should arrive today to use for rolling out some Windows 10 Pro Client images on the X240s and possibly also this Linux stuff with the Mint installer and your installer both on them.

One further thing I should mention is that on our RPi build for RACHEL on the SolarBerry one of my colleagues set up a DNS service so the users just need to type “rachel” into the browser client address bar to access it on the server. Just a nice little touch I think.

Keep up the great work!

Regards
Andrew

Hi Andrew,

Currently DHCP is provided over wlan through a setting at the end of the dnsmasq.conf file. Dnsmasq is handling DHCP and assigning IP addresses in the 10.10.10.x range set there for the wlan interface. I believe adding wired DHCP is as simple as adding a similar setting in that file but with the ethernet interface and another range like 11.11.11.11. This is something I can automate and add into the installer and we can test.

It looks ilke the best way to set these devices up is to install everything and then configure what is or isn’t needed afterwards with a separate utility. That way everything is always available if needed, but not always turned on when not. Turning this stuff on and off is generally as simple as a few systemctl commands so it really shouldn’t be hard to create a script with a user interface to make it easy.

Looking at the question again, transfering modules to the main device that’s hosting RACHEL from a USB stick would be the easiest. All you would need to do is transfer the modules from USB to /var/www/modules and run “sudo chown -R www-data:www-data /var/www/modules” and it should be done. An rsync server would only be useful for updating many RACHEL main devices.

If you have content that’s very large and over the size of your USB sticks, you can turn ssh on for the RACHEL device and then transfer it from another device using WinSCP. This would be over the network. I think the last resort would be the rsync server if those don’t work.

James

Hi James

It looks like the best way to set these devices up is to install everything and then configure what is or isn’t needed afterwards with a separate utility.

That sounds fine to me. The guys out there don’t have much Linux experience (although we are trying to get them some training) and I am reluctant to ask them to edit files manually as they can get it very wrong when they don’t know what they are doing.

My original plan was to have each school use 192.168.x.0 range where x is unique to the school as that would allow for any future WLAN connection, and we have only about 200 schools in the Northern Region.

If we could configure these things through a GUI interface that would be great.

Regarding copying RACHEL modules would it be possible to have a small script to copy the complete modules and change the ownership of them? that would seem like a better route than rsync. We can keep the content on a USB stick, USB HDD or on a Master laptop, whatever is best.

Regards
Andrew
PS I got notification of your post by email tonight so something has fixed it!

1 Like

Hi Andrew,

This is a huge project ( 200 schools. Wow. ) so I understand that there may be some hickups with that many deployments. I make mistakes editing files sometimes too. Automating everything with a GUI should cut down on any issues.

There are a few ways that could work. The easiest for the user would be to integrate this functionality into an extra RACHEL admin interface page. This way they could do everything from the same web interface. The issue with that is I then have to give sudo permissions for any of those functions to the web user ( www-data ) which means anyone connected could possibly run it. Another option is a script and interface similar to the installer which they would have to run in a terminal with something like “sudo rachel-config”, then select the option they want to change. That is more secure but requires a little bit of knowledge to run.

We should be able to change the dhcp ranges if you want them to be unique to each school. This would have to be changed in a few files and added to the configuration utility/installer options. I’ll put that on the list of things to add.

For copying RACHEL modules from USB I think using Linux Mint’s file manager is going to be better than anything I can create. Just dragging and dropping the folders over would work and would have a proper progress bar whereas anything I scripted wouldn’t be as easy to use. I could add the part where it takes ownership to the configuration utility. The taking ownership part is required so that they can be deleted from the admin interface but I think they should work even without that step. That would be the best procedure. Generally I would say that having all of the content on the device already before deployment is the best but i realize there will be updates to content in the future.

Glad you got a notification!

James

Hi James

Yes, it is a big project and will take years but to put it in perspective we have already installed around 80 schools labs. However only a handful have networks mainly due to local resource constraints (e.g. schools unable to afford cabling). The overall plan is even bigger than just the Northern Region and we are already looking at rolling it out to the Central Region.

something like “sudo rachel-config”

Yes, that would be workable I think if it provided a menu-based system to configure the system.

What happens in practice is that our local partners in Mzuzu employ technicians to build machines in their local office and then deploy all hardware to the schools. They are more familiar with Windows-based systems but could follow a set of instructions for deployment of Linux systems if I provided that. That could include DHCP config for wired and wireless networks.

For copying RACHEL modules from USB I think using Linux Mint’s file manager is going to be better than anything I can create.

I’m fine with that idea if we provide instructions to change the ownership. That seems to me relatively straightforward to do in Mint although I’m not sure if they need to run the File Manager with elevated privileges to do it?

Does just copying the modules into the correct folder that way result in updating the RACHEL menus with the added items in the same way as when you add them in the Admin interface?

Regards
Andrew

Hi Andrew,

If they’re logged in as sudo user on the desktop they should just be able to drag the modules from the USB stick to /var/www/modules and then when the page is refreshed the modules show in RACHEL. So on their end they’d just drag and drop, run the config utility, and select the option to take ownership. Kiwix has to be restarted for wikipedia modules to work, so I could just add that to the take ownership option in the config utility. We could call it “complete module transfer” or something and it will do the rest.

The networking stuff is going to be more confusing for people and something we should be sure is 100% working in advance. I have mint installed on a separate harddrive so I can properly test everything but I’m having issues right now with my wifi interface not being recognized. I’m trying with an edimax wifi adapter from the pi today to see if it works. It shouldn’t be long afterwards as the network manager files seem pretty straight forward.

James

Hi James

That’s fine re the module transfer option.

I recall there was an issue with Ubuntu and Intel WiFi N adaptors for a while (the workaround solution being to downgrade the adaptor to a slower G speed) but that may not apply to Mint. The only issue I had was that it wouldn’t upgrade the driver but as it works fine with the default driver I just left it as it was.

Look forward to testing your next release when its is ready.

Regards
Andrew

Hey Andrew,

Just an update to where I’m at. I got the edimax adapter working so I can test all of the wifi stuff now. The installer is Python and Python does have a library for working with NetworkManager so I’m trying to use this to create the hotspot connection because there are some settings that I think need to be generated by it like the UUID. The MAC Address and other settings also have to be added for each device and it would be cleaner with this, but it’s not that well documented. I might just go the route of transfering a modified version of the connection file you pasted to me if I can’t figure this out to move ahead faster.

I’m also going to incorporate as many of the new features we discussed as possible before the next test so it may be a bit longer but that would mean less testing. If there are any other features or things you’d like that you’ve discussed with colleagues I’d be happy to incorporate them into this version.

James

Hi James

Fine re your plans for the new installer. Best to take time and get it as right as possible as it is much more difficult to support if it goes wrong once it is deployed in Africa!

I may put another HDD in the test laptop to start with a clean bare-metal build. I have prepared some USB memory sticks with Mint 19.3 installer on them to boot the new OS and I will add your stuff when it is ready.

Regards
Andrew

1 Like

Hi Andrew,

You mentioned wanting to do 192.168.x. where x is unique for each school, so we’ll need two ranges. One for wifi and one for LAN if it’s enabled. What would you like to use instead of 10.10.10.10 or 11.11.11.11? The installer will then ask the question for the school number to fill in that x automatically. Does that make sense? The main obstacle with this setup is that it’s not consistent for each school and they’d have to know their number, so if DNS wasn’t working for some reason they’d have to guess the IP to get to RACHEL whereas with one default across the board any school would be have rachel accessible at 10.10.10.10 or 11.11.11.11. Just want to work this out before continuing

Sounds good on everything else.

James

Hi James

We have been used to using 10.10.10.10 on WiFi for all the RPi installations to access RACHEL so I would stick to that range for WiFi DHCP.

And if you could do 192.168.x.0 for DHCP on the wired connection the technician installing it would choose x for that school and set it up accordingly for them.

(S)he would also work out whether the school already have a DHCP server and thus choose to switch it on or off for each of these subnets. They would also document what they had done at the school for future tech staff who might visit.

Hope that makes sense.

Regards
Andrew