Need Help with Samba

Hi guys, i'm kind of new and almost killed my new router Archer C2600 yesterday!! There is a lot i didn't knew about programming and CLI via Putty but I learned a lot yesterday. I was finnaly able to get my router back on (i had problem with 2.4ghx b4 i installed lede) and luci installed to manage via web interface.

I was looking into trying to setup the USB3.0 i have on the router to share the files among all my pc/phone at home. I found a lot of information on samba and how to configure it but I just can't manage to see any link to how to install the package itself. I'm not finding anything under opkg list or else.
I found this (see below) on openwrt but the packages doesn't seems to be present into the repository when i type in : opkg install block-mount, for example.

Sorry for my low knowledge, but we gotta start somewhere! ty

You will find detailed walk troughs for USB-storage and Samba respectively. As a minimum you will need to install the packages kmod-usb-storage, block-mount, samba36-server and luci-app-samba. In addition you will need support for the file system you format the USB device with. For ext file-systems install kmod-fs-ext4, for btrfs install kmod-fs-btrfs. Avoid using ntfs from Microsoft, it lacks a couple of important features for file-systems. But if you still want to use it, install ntfs-3g in order to have read & write access.

Before you can install packages you need to run the command "opkg update" to download the latest list of packages. The list and the packages are not stored on your device.

See the wiki for using the package manager here:[]=opkg

When using trunk images you probably want to download (all) the packages to your local machine at the same time that you download the image. About 400MB of space. When trunk is rebuilt, the packages may change and you may have issues installing them, especially if they are kernel dependent. See the distfeeds.conf file to find where to get the packages for your device.

Hint: You can use the USB stick to store your packages and access them via exroot or samba share. The path to the packages is stored in the /etc/opkg/distfeeds.conf file.

Well I already know how to use the opkg update since I needed it to install the LuCi web interface. My problem is more related to how to find the packages. how can i check the disfeeds file? i tried typing distfeeds.conf or /etc/opkg/distfeeds.conf in Putty but I'm getting permission denied in the second attemps. Sry I'm not a programmer so there is some basic programmation stuff i sometimes miss (the reason why i ussualy find the tutorial kind of hard)

If you want compatibility between OSes the exfat filesystem is probably your best bet, only downside right now is that it isn't recognized by block-mount out of the box.

Hi there.
You say "the packages doesn't seems to be present into the repository when i type in : opkg install block-mount, for example."

Can you write opkg update (and press Enter), then post what is printed on the Putty screen, then write opkg install block-mount (and press Enter), and post again what is printed on Putty screen, then do the same with opkg list ?

This way we can see what is the error it says (if any).

If you want to search for a package, I usually do a opkg list | grep "keyword" (opkg list lists all packages in the repository, the "|" pipes the text to a tool called grep that will filter that and show only lines containing the word "keyword" (without the "").

For Samba, you will probably want to install the package called luci-app-samba which is the package providing a luci interface for Samba. It will trigger the installation of Samba and other needed stuff too.

And yes, you need kmod-fs-ext4 package that is the driver for ext4, the most common linux filesystem, e2fsprogs package that contains the tools to format the drive as ext4, plus block-mount.

Please note, the drive connected to the device will have to be formatted, so all data on it will be DELETED, please move all your data off it first, you will add that back later through Samba's shared folders.

Once you have installed them and connected the drive to the usb port you write block info to see what partitions are there.

example output
root@lede:/# block info
/dev/mtdblock2: UUID="9fd43c61-c3f2c38f-13440ce7-53f0d42d" VERSION="4.0" MOUNT="/rom" TYPE="squashfs"
/dev/mtdblock3: MOUNT="/overlay" TYPE="jffs2"
/dev/sda1: UUID="fdacc9f1-0e0e-45ab-acee-9cb9cc8d7d49" VERSION="1.4" TYPE="f2fs"

/dev/sdxx is the name given to the drive you have connected to the usb.

Then you can format it as ext4 with the command said here
and then proceed with the tutorial to add the mount point of it to the fstab, so it is mounted at boot automatically, and will be usable for samba.

Hi, thank you for the help by the way. I just realized that I was trying to install stuff in new session (had to run opkg update for a 4th time) because I was finally able to install what you told me. I ran into trouble with the kmod one, all the rest went well;

root@lede:~# opkg install kmod-fs-ext4
Installing kmod-fs-ext4 (4.4.39-1) to root...
Collected errors:

  • satisfy_dependencies_for: Cannot satisfy the following dependencies for kmod-fs-ext4:
  •  kernel (= 4.4.39-1-1cf49d05d164a73cd0ba311b3e63ea89) *  kernel (= 4.4.39-1-1cf49d05d164a73cd0ba311b3e63ea89) *  kernel (= 4.4.39-1-1cf49d05d164a73cd0ba311b3e63ea89) *  kernel (= 4.4.39-1-1cf49d05d164a73cd0ba311b3e63ea89) *
  • opkg_install_cmd: Cannot install package kmod-fs-ext4.

I ran a vi /etc/openwrt_release so check what I had installed. (my router is a Tp-Link C2600 V1.0)


  • /etc/openwrt_release 1/7 14%

Also, I was wondering, If I'm able to share the drive with everything in my home, do you know about any app able to make it sync with another HDD in one of my PC in order to create a sort of backup? Is it something that people already worked on?

Thanks again.

I ran into trouble with the kmod one, all the rest went well

Ok, the issue seems to be caused by the fact that this package was built for a slightly newer version of the kernel.

Currently LEDE has only "snapshot builds", that are rebuilt every few days from source, and if something changes in the kernel, all packages that have that as a dependency will not install anymore unless you update the kernel too.
The only way to update the kernel is to upgrade the firmware to the current one, then install the kmod package asap.

A release should happen soon (see here), and in a release build this should not happen as things are kept stable for obvious reasons.

If I'm able to share the drive with everything in my home, do you know about any app able to make it sync with another HDD in one of my PC in order to create a sort of backup?

If you use Samba (Windows shared folders) to share files with a windows PC, the shared folder will appear as a normal folder to windows programs, so you can set up a file copy on a schedule to sync data.
For example with you can do that and also specify that it has to delete files not present in the source drive (so that when you delete a file in your hard drive, it will be deleted from the backup too when the sync runs)

I am trying to get Samba installed as well, but the package samba36-server, or any other Samber server package, is not available. I am currently running the following version of LEDE: LEDE Reboot SNAPSHOT r4830-c88770c / LuCI Master (git-17.255.51369-6d4370d). Can anyone advise on how to get the samba server package? Thanks!