• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

[Tutorial] How to run TFS on Android device [NO ROOT NEEDED]

Is TFS on smartphone have sens?

  • Of course!

    Votes: 5 31.3%
  • It's only a curiosity.

    Votes: 8 50.0%
  • Nonsense.

    Votes: 1 6.3%
  • Only in some case.

    Votes: 2 12.5%

  • Total voters
    16

MagicWall

Veteran OT User
Joined
Oct 12, 2008
Messages
124
Solutions
6
Reaction score
344
I remember times when OTServList was been full of non-commercial OTS creating by fans for fun. When server was been hosted on PC. Maybe uptime was intermittent, but it was worth to wait for it. So, maybe I want to show that tutorial, I was searched solution for that, from melancholic reasons. But it doesn't matter ...

So, when I have found Termux project in web, I was thinking about that all possibilities who giving us linux on Android device.

Today smartphones have 4-8 GB RAM, ~a lot of cores (yeah I know - weaks, but 7-14nm looks good), but some of us started with one core and 512MB RAM so maybe it is worth a try. Additionally smartphones have some benefits, it's quiet, economy, small.

Ok, let's start to run TFS on smartphone.

1) First download Termux from Google Play.

Termux_start.png


* If you don't think that touch screen is not good think to writing in terminal (like me) download putty and run command sshd in Termux terminal.
Bash:
sshd

Then set your host name (your smartphone ip adress) and port 8022 in PuTTY.

Termux_PuTTY.png


Other remote access possibilities:

2) Install for example debian 9.
For that we use this project:

Bash:
cd /data/data/com.termux/files/home
apt update
apt install wget
hash -r
wget https://raw.githubusercontent.com/sp4rkie/debian-on-termux/master/debian_on_termux.sh
sh debian_on_termux.sh
Installation may take some part of time, up to ~30+ minutes.

3) Run Debian 9

Bash:
$HOME/bin/enter_deb

4) Install database.

Bash:
apt update
apt upgrade

Bash:
apt install mariadb-server

If you have problem with installation, restart Termux.

5) Install the required software.

Bash:
apt-get install git cmake build-essential liblua5.2-dev mariadb-client default-libmysqlclient-dev libgmp3-dev libboost-system-dev libboost-iostreams-dev libpugixml-dev libcrypto++-dev

In this case I was had problem with mysql libs (from TFS wiki). So I change it to MariaDB (with problems), so in this place we may have problem.

6) Clone repo.

Bash:
cd /usr

git clone --recursive https://github.com/otland/forgottenserver.git

cd forgottenserver
mkdir build && cd build
cmake ..

make

cp tfs ..

7) Configure TFS config.lua/config.lua.dist

Code:
cd /usr/forgottenserver

nano config.lua.dist

Change config.lua.dist or config.lua
Ip, mysqlPass and other.

8) Start database.

Bash:
cd /etc/init.d
./mysql start

9) Configure database.

Bash:
mysql
CREATE DATABASE forgottenserver
use forgottenserver
source /usr/forgottenserver/schema.sql

CREATE USER 'USER_NAME_HERE'@'127.0.0.1' IDENTIFIED BY 'PASSWORD_HERE';

quit

10) Run TFS.

Code:
cd /usr/forgottenserver
./tfs

Termux_PuTTY_result.png


Then we may add website (PHP, webserver etc.).

In point 9 we may add account and character in database.
SQL query: God account on TFS 1.3 + premium, via sql (https://otland.net/threads/god-account-on-tfs-1-3-premium-via-sql.251861/)

Maybe I add later some screens/videos.
 
Last edited:
I wonder if the lack of comments on this kind of thread means they're really awesome and work perfectly. 🙃
Gonna test it soon, by the way. Got some free storage available! 🤩
 
I mean this is just awesome, not long ago people didn't even know what mobile phones are and nowadays this 😝

Big 👍
 
Don't know what happened to this, is it really working? xD
 
Don't know what happened to this, is it really working? xD

Yes it really works. There are even web servers for android: apache + mysql.

Those can be installed through Google Play.

I tried once this: AWebServer ( Http Web Server Apache PHP Sql ) - Apps on Google Play (https://play.google.com/store/apps/details?id=com.sylkat.apache&gl=DE)

But, there are way more.

You can run for example MyAAC in your Android device.

And anything, that works with PHP, like WordPress, etc.

There is even MySQL Server and you can also have PhpMyAdmin or anything you wish.

It's not so hard to get it working. You need just copy files to correct folder.
 
Back
Top