WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Upgrade samba to latest version for TCL x86  (Read 4518 times)

Offline bonbob

  • Jr. Member
  • **
  • Posts: 99
Upgrade samba to latest version for TCL x86
« on: October 05, 2018, 02:25:54 AM »
Can anyone upgrade SAMBA extension for TCL x86?
For corepure64 it ver. 4.6.3 and 3.6.25 for TCL x86.

Offline bonbob

  • Jr. Member
  • **
  • Posts: 99
Re: Upgrade samba to latest version for TCL x86
« Reply #1 on: October 06, 2018, 12:38:22 AM »
samba3 not working. In Log-file:
Code: [Select]
samba regdb_init: unknown registry versionGoogle says i need upgrade samba to newest version 4.x. I said "OK GOOGLE" and download samba latest source files ver 4.9.1.
But compilation was not successful.
I've got an error
Code: [Select]
rpcgen: not foundGoogle helps me again:
Quote
In order to support NIS and NFS we need to use libtirpc, libnsl2 and rpcsvc-proto
So i stuck again. There is no rpcsvc-proto.tcz in repository.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11631
Re: Upgrade samba to latest version for TCL x86
« Reply #2 on: October 06, 2018, 12:58:20 AM »
Hi bonbob
Quote
So i stuck again. There is no rpcsvc-proto.tcz in repository.
Try installing  glibc_base-dev.tcz.  I believe it provides the needed files.

Offline bonbob

  • Jr. Member
  • **
  • Posts: 99
Re: Upgrade samba to latest version for TCL x86
« Reply #3 on: October 06, 2018, 11:40:19 AM »
i have installed glibc_base-dev.tcz, but compiler still searching rpcgen  :-[

maybe someone knows how to make samba3 working on TCL 9.0? I remembrer it was fine on TCL 8.x
« Last Edit: October 06, 2018, 11:42:42 AM by bonbob »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11631
Re: Upgrade samba to latest version for TCL x86
« Reply #4 on: October 06, 2018, 12:12:07 PM »
Hi bonbob
It's supposed to be in  glibc_apps.tcz,  but the TC9 version of  glibc_apps.tcz  is missing that program. The 64 bit TC9
version of  glibc_apps.tcz  does contain the  rpcgen  program. Both 32 and 64 bit versions in TC8 have  rpcgen  included
in  glibc_apps.tcz,  so this was probably just an oversight. I think Juanito might have to fix this.

Offline bonbob

  • Jr. Member
  • **
  • Posts: 99
Re: Upgrade samba to latest version for TCL x86
« Reply #5 on: October 06, 2018, 12:21:24 PM »
Now it is not necessary. I deleted all files in /var/lib/samba an restarted samba3. After that
error regdb_init: unknown registry version 3 (code version = 2) has gone and samba3-server launched succesfully.  :)
Maybe later someone upgrade samba for x86, but now my problem solved

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11631
Re: Upgrade samba to latest version for TCL x86
« Reply #6 on: October 06, 2018, 12:25:37 PM »
Hi bonbob
So it sounds like you are saying you got the 64 bit version running, is that correct?

Offline bonbob

  • Jr. Member
  • **
  • Posts: 99
Re: Upgrade samba to latest version for TCL x86
« Reply #7 on: October 06, 2018, 01:05:09 PM »
Recently i got a thin client with VIA Eden processor on board. It is i686 cpu and it do not work with CorePure64. Before it i used CorePure64 on broken notebook as a home mediaserver. I have migrated with all shell scripts and config files in mydata.tgz from CorePure64 то TCLx86. So all *.tdb files for samba4 was copied too.  Error message contains answer, that tdb version is 3, but samba3 need version 2. Another question that SMB1 protocol is deprecated in windows 10 by security reasons, and disabled by default . It better to upgrade samba to SMB2 or even SMB3. 

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14818
Re: Upgrade samba to latest version for TCL x86
« Reply #8 on: October 19, 2018, 08:28:20 AM »
Hi bonbob
It's supposed to be in  glibc_apps.tcz,  but the TC9 version of  glibc_apps.tcz  is missing that program.

In fact the list file was missing rpcgen, but the extension contains rpcgen - list file updated

Offline bonbob

  • Jr. Member
  • **
  • Posts: 99
Re: Upgrade samba to latest version for TCL x86
« Reply #9 on: January 06, 2019, 07:32:33 AM »
Finally I made it!
samba 4.9.4 for x86 compiled successfully. Strange thing, but new samba4 extension is only 10,7Mbytes instead old samba3, which need 32Mbytes disk free space. There is Tiny Core Philosophy in action.  :)

Offline akelio

  • Newbie
  • *
  • Posts: 5
Re: Upgrade samba to latest version for TCL x86
« Reply #10 on: January 31, 2019, 06:58:50 AM »
Finally I made it!
samba 4.9.4 for x86 compiled successfully. Strange thing, but new samba4 extension is only 10,7Mbytes instead old samba3, which need 32Mbytes disk free space. There is Tiny Core Philosophy in action.  :)
Hey, it would be great if you share new extension or, at least, instructions for compiling!

Offline bonbob

  • Jr. Member
  • **
  • Posts: 99
Re: Upgrade samba to latest version for TCL x86
« Reply #11 on: February 01, 2019, 12:28:29 PM »
Ok. Here is a few steps to make your own samba for TCL:

1. get latest version of samba from samba.org

2. unpack archive samba-latest.tar.gz somewhere, for example /home/tc

3. get all necessary extensions:

compiletc
perl5
jansson-dev
gnutls-dev
or newer version gnutls3.6-dev on your choice
python-dev
glibc_apps


4. go to the samba DIR, for example
Code: [Select]
cd /home/tc/samba4
5. set necessary flags
for x86:
Code: [Select]
export CFLAGS="-march=i486 -mtune=i686 -Os -pipe"
export CXXFLAGS="-march=i486 -mtune=i686 -Os -pipe"
export LDFLAGS="-Wl,-O1"

or for x86_64
Code: [Select]
export CFLAGS="-mtune=generic -Os -pipe"
export CXXFLAGS="-mtune=generic -Os -pipe"
export LDFLAGS="-Wl,-O1"

6. if you need samba only as file-server for WIN configure samba with this options:

sudo ./configure
 -- disable-python
 -- without-ad-dc
 -- without-gpgme
 -- without-libarchive
 -- without-acl-support
 -- without-ldap
 -- without-ads
 -- without-pam

it's configure an minimalistic samba, lightweight as it possible


7. make-install:
Code: [Select]
sudo make
 install DESTDIR=/home/tc/package

Compilation takes some time. On my xeon processor with 4 cores 3.2 GHz and 4Gb ram it takes near 15-17 minutes

After all you can get your samba in /home/tc/package

How to pack samba onto squashfs you can read on wiki.tinycorelinux.net/wiki:creating_extensions

Don't forget to create .dep file with such dependencies:

expat2.tcz
jansson.tcz
gnutls.tcz
(or gnutls3.6.tcz if you choose this one)

Offline akelio

  • Newbie
  • *
  • Posts: 5
Re: Upgrade samba to latest version for TCL x86
« Reply #12 on: February 08, 2019, 05:19:13 AM »
Great work, thanks a lot!