SIMPLE ALL IN ONE: From nothing to a fully working dedicated server on Ubuntu

Mister Budex

BudexOT.com
Premium User
Joined
Jun 22, 2016
Messages
1,146
Reaction score
197
@Don Daniello

Server crash and this appear on console. What does it mean and what makes it occur?
Just an crash.
You have to install gdb and you can see crash error
write this in your putty console :
apt-get install gdb
then start it with gdb and u can see errors :)
 

Itutorial

Advanced OT User
Joined
Dec 23, 2014
Messages
1,440
Reaction score
316
How can I add SSL to my website? Most tutorials tell me to look for: apache2/enables-sites or httpd folder. I do not have either of those. What do I need to do?
 
OP
Don Daniello

Don Daniello

/root
Staff member
Administrator
Joined
Apr 11, 2008
Messages
3,468
Reaction score
818
Location
Proland
How can I add SSL to my website? Most tutorials tell me to look for: apache2/enables-sites or httpd folder. I do not have either of those. What do I need to do?
e..g using "certbot --nginx"
 

tanii

Empire-war.com
Joined
Jan 16, 2015
Messages
381
Reaction score
9
How can I add SSL to my website? Most tutorials tell me to look for: apache2/enables-sites or httpd folder. I do not have either of those. What do I need to do?
For enable ssl certificate u should go to domain settings.
 

jesse.b

New Member
Joined
Nov 30, 2018
Messages
3
Reaction score
0
Hello I am trying to get this running on ubuntu 16.04 and I have a few issues:

First there is a date command issue:
Code:
$ duedate
date: option requires an argument -- 'd'
Try 'date --help' for more information.
But more importantly I can't seem to get the server to start:

Code:
$ log tfs
-- Logs begin at Thu 2018-11-29 23:31:18 UTC, end at Thu 2018-11-29 23:39:50 UTC. --
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Started The Forgotten Server.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[2195]: tfs.service: Failed at step EXEC spawning /home/otsmanager/forgottenserver/build/tfs: No such file or directory
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Main process exited, code=exited, status=203/EXEC
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Unit entered failed state.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Failed with result 'exit-code'.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Service hold-off time over, scheduling restart.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Stopped The Forgotten Server.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Started The Forgotten Server.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[2197]: tfs.service: Failed at step EXEC spawning /home/otsmanager/forgottenserver/build/tfs: No such file or directory
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Main process exited, code=exited, status=203/EXEC
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Unit entered failed state.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Failed with result 'exit-code'.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Service hold-off time over, scheduling restart.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Stopped The Forgotten Server.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Started The Forgotten Server.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[2199]: tfs.service: Failed at step EXEC spawning /home/otsmanager/forgottenserver/build/tfs: No such file or directory
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Main process exited, code=exited, status=203/EXEC
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Unit entered failed state.
Nov 29 23:38:05 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Failed with result 'exit-code'.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Service hold-off time over, scheduling restart.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Stopped The Forgotten Server.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Started The Forgotten Server.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[2201]: tfs.service: Failed at step EXEC spawning /home/otsmanager/forgottenserver/build/tfs: No such file or directory
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Main process exited, code=exited, status=203/EXEC
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Unit entered failed state.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Failed with result 'exit-code'.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Service hold-off time over, scheduling restart.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Stopped The Forgotten Server.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Started The Forgotten Server.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[2203]: tfs.service: Failed at step EXEC spawning /home/otsmanager/forgottenserver/build/tfs: No such file or directory
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Main process exited, code=exited, status=203/EXEC
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Unit entered failed state.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Failed with result 'exit-code'.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Service hold-off time over, scheduling restart.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Stopped The Forgotten Server.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Start request repeated too quickly.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: Failed to start The Forgotten Server.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Unit entered failed state.
Nov 29 23:38:06 b7ffcf8c-39c5-44a0-b21f-c831f718d957 systemd[1248]: tfs.service: Failed with result 'start-limit-hit'.
Contents of the directory it's looking for the tfs file in:

Code:
$ ls -l /home/otsmanager/forgottenserver/build/
total 20
-rw-r--r-- 1 otsmanager otsmanager 12685 Nov 29 23:29 CMakeCache.txt
drwxr-xr-x 4 otsmanager otsmanager  4096 Nov 29 23:29 CMakeFiles
Any suggestions? Please let me know if you need any more information.
 
OP
Don Daniello

Don Daniello

/root
Staff member
Administrator
Joined
Apr 11, 2008
Messages
3,468
Reaction score
818
Location
Proland
@jesse.b The duedate command only works when you purchase hosting service from me, otherwise it will throw an error.

It looks like the compilation step didn't work when you ran the playbook via Ansible and you don't have tfs compiled.
Go into /home/otsmanager/forgottenserver/build/ and run make ..
 

jesse.b

New Member
Joined
Nov 30, 2018
Messages
3
Reaction score
0
Yeah it's failing on that step:

Code:
TASK [Cmake forgottenserver source] ********************************************
fatal: [localhost]: FAILED! => {"changed": true, "cmd": ["cmake", ".."], "delta": "0:00:02.259513", "end": "2018-11-30 11:51:15.124128", "failed": true, "rc": 1, "start": "2018-11-30 11:51:12.864615", "stderr": "CMake Error at /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:148 (message):\n  Could NOT find Crypto++ (missing: Crypto++_INCLUDE_DIR Crypto++_LIBRARIES)\nCall Stack (most recent call first):\n  /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:388 (_FPHSA_FAILURE_MESSAGE)\n  cmake/FindCrypto++.cmake:11 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)\n  CMakeLists.txt:24 (find_package)", "stdout": "-- The C compiler identification is GNU 5.4.0\n-- The CXX compiler identification is GNU 5.4.0\n-- Check for working C compiler: /usr/bin/cc\n-- Check for working C compiler: /usr/bin/cc -- works\n-- Detecting C compiler ABI info\n-- Detecting C compiler ABI info - done\n-- Detecting C compile features\n-- Detecting C compile features - done\n-- Check for working CXX compiler: /usr/bin/c++\n-- Check for working CXX compiler: /usr/bin/c++ -- works\n-- Detecting CXX compiler ABI info\n-- Detecting CXX compiler ABI info - done\n-- Detecting CXX compile features\n-- Detecting CXX compile features - done\n-- cotire 1.7.6 loaded.\n-- Performing Test COMPILER_KNOWS_CXX11\n-- Performing Test COMPILER_KNOWS_CXX11 - Success\n-- Performing Test COMPILER_KNOWS_STDLIB\n-- Performing Test COMPILER_KNOWS_STDLIB - Failed\n-- Performing Test COMPILER_KNOWS_LTO\n-- Performing Test COMPILER_KNOWS_LTO - Success\n-- Configuring incomplete, errors occurred!\nSee also \"/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeOutput.log\".\nSee also \"/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeError.log\".", "stdout_lines": ["-- The C compiler identification is GNU 5.4.0", "-- The CXX compiler identification is GNU 5.4.0", "-- Check for working C compiler: /usr/bin/cc", "-- Check for working C compiler: /usr/bin/cc -- works", "-- Detecting C compiler ABI info", "-- Detecting C compiler ABI info - done", "-- Detecting C compile features", "-- Detecting C compile features - done", "-- Check for working CXX compiler: /usr/bin/c++", "-- Check for working CXX compiler: /usr/bin/c++ -- works", "-- Detecting CXX compiler ABI info", "-- Detecting CXX compiler ABI info - done", "-- Detecting CXX compile features", "-- Detecting CXX compile features - done", "-- cotire 1.7.6 loaded.", "-- Performing Test COMPILER_KNOWS_CXX11", "-- Performing Test COMPILER_KNOWS_CXX11 - Success", "-- Performing Test COMPILER_KNOWS_STDLIB", "-- Performing Test COMPILER_KNOWS_STDLIB - Failed", "-- Performing Test COMPILER_KNOWS_LTO", "-- Performing Test COMPILER_KNOWS_LTO - Success", "-- Configuring incomplete, errors occurred!", "See also \"/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeOutput.log\".", "See also \"/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeError.log\"."], "warnings": []}
Trying to run manually:
Code:
[email protected]:/home/otsmanager/forgottenserver/build$ sudo make
make: *** No targets specified and no makefile found.  Stop.
Code:
[email protected]:/home/otsmanager/forgottenserver/build$ sudo cmake .
-- cotire 1.7.6 loaded.
CMake Error at /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:148 (message):
  Could NOT find Crypto++ (missing: Crypto++_INCLUDE_DIR Crypto++_LIBRARIES)
Call Stack (most recent call first):
  /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:388 (_FPHSA_FAILURE_MESSAGE)
  cmake/FindCrypto++.cmake:11 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  CMakeLists.txt:24 (find_package)


-- Configuring incomplete, errors occurred!
See also "/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeOutput.log".
See also "/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeError.log".
CMakeOutput.log: Contents of CMakeOutput.log

CMakeError.log:
Code:
$ cat /home/otsmanager/forgottenserver/build/CMakeFiles/CMakeError.log
Performing C++ SOURCE FILE Test COMPILER_KNOWS_STDLIB failed with the following output:
Change Dir: /home/otsmanager/forgottenserver/build/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/make" "cmTC_66554/fast"
/usr/bin/make -f CMakeFiles/cmTC_66554.dir/build.make CMakeFiles/cmTC_66554.dir/build
make[1]: Entering directory '/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeTmp'
Building CXX object CMakeFiles/cmTC_66554.dir/src.cxx.o
/usr/bin/c++     -DCOMPILER_KNOWS_STDLIB   -stdlib=libc++ -o CMakeFiles/cmTC_66554.dir/src.cxx.o -c /home/otsmanager/forgottenserver/build/CMakeFiles/CMakeTmp/src.cxx
c++: error: unrecognized command line option '-stdlib=libc++'
CMakeFiles/cmTC_66554.dir/build.make:65: recipe for target 'CMakeFiles/cmTC_66554.dir/src.cxx.o' failed
make[1]: *** [CMakeFiles/cmTC_66554.dir/src.cxx.o] Error 1
make[1]: Leaving directory '/home/otsmanager/forgottenserver/build/CMakeFiles/CMakeTmp'
Makefile:126: recipe for target 'cmTC_66554/fast' failed
make: *** [cmTC_66554/fast] Error 2

Source file was:
int main() { return 0; }
 

jesse.b

New Member
Joined
Nov 30, 2018
Messages
3
Reaction score
0
I started with a fresh install and ensured to install Crypto++ before running ansibile and it seems to work now. I still get a failed to connect to bus error initially but I was able to solve that using:

Code:
export XDG_RUNTIME_DIR=/run/user/`id -u`
Which I saw you recommend earlier in the thread. I am using su - though but I will just add that line to otsmanager's bashrc.

Thanks for the help!
 
OP
Don Daniello

Don Daniello

/root
Staff member
Administrator
Joined
Apr 11, 2008
Messages
3,468
Reaction score
818
Location
Proland
@jesse.b I see now what it is. I've fixed the playbook.
libcrypto++-dev package was missing.
 

elnelson

Lunaria World Dev
Joined
Jun 20, 2009
Messages
456
Reaction score
23
Location
México
Hey Daniello! i've been trying to set up this but i've failed in two ways:
-I've tried with ubuntu 15.04 just as tutorial says, but i encounter several error since update (most of them says something like; 404 not found [ip: 91.189.91.23 80])... tons of archives are not found and have been ignored. after that, i can not install the second line (the python ones) says "Unable to locate package python-paramiko, Unable to locate package python-yaml, UTLP python-jinja2, UTLP python-simplejson and UTLP ansible" theremore it fails, can not install the ansible neither...

Edit: I found in internet that the Ubuntu server 15.04 has end of life, thats why i can not update. so what can i do now?

-Also tried with ubuntu 16.04 and succesfully installed the ansible but, when i try the command serverip it says "Device eth0 does not exist". Also i sometimes get a critical error when i explore the terminal

Edit2: Found that Eth0 is not supported by ubuntu 16.04 anymore x.x, so i followed this guide: Changing Network Interfaces name Ubuntu 16.04
but when i type serverip it wont show anything.

So i can not configure this... i dont know anything about linux i just follow the raw instructions as the post says. I've been trying for like 7 hours from now but i can not make it work, also tried several times fresh start but i get the same errors... What could be wrong? i just want to host my server lol
 
Last edited:
OP
Don Daniello

Don Daniello

/root
Staff member
Administrator
Joined
Apr 11, 2008
Messages
3,468
Reaction score
818
Location
Proland
-Also tried with ubuntu 16.04 and succesfully installed the ansible but, when i try the command serverip it says "Device eth0 does not exist". Also i sometimes get a critical error when i explore the terminal
You are right, it says the script supports Ubuntu 15.04, but your mirrors don't serve 15.04 packages, so it's not really a problem I can solve for you. You should switch to newer version - like you did.
Now about the interface name, the installations I use still have eth0 but the `serverip` command is simply just an alias - you can edit the script called `.otsmanager` to update interface name from eth0 to anything else you want.
 

elnelson

Lunaria World Dev
Joined
Jun 20, 2009
Messages
456
Reaction score
23
Location
México
You are right, it says the script supports Ubuntu 15.04, but your mirrors don't serve 15.04 packages, so it's not really a problem I can solve for you. You should switch to newer version - like you did.
Now about the interface name, the installations I use still have eth0 but the `serverip` command is simply just an alias - you can edit the script called `.otsmanager` to update interface name from eth0 to anything else you want.

Thanks for your answer, Daniello. I got an advance in the server. But i got stuck trying to stablish SQL database, i've been reading your guides but i cant find where are stored the databases.
This is because i have my own Database structure and i need to import it to the server.
Also tried to connect with the default database (as i know the default is named forgottenserver)
to fasten the description, there is a pic of the configuration i used (set the user and pw given by the system)

But i got an error: Access denied for user 'otsmanager' @ localhost (using password: YES)
therefore i cant stablish connection with SQL...

Im very happy i could compile and open my sources, but i got stuck here, would be very pleased if u could help me how to mount my own db (that is already inside my server) and why is not connecting.
 

Attachments

Shadow_

asgard-ot.com
Premium User
Joined
Jun 2, 2018
Messages
322
Reaction score
60
Location
Cairo, Egypt
failed: [localhost] => (item=[u'lxc', u'lxd', u'snapd']) => {"failed": true, "item": ["lxc", "lxd", "snapd"], "msg": "'apt-get remove 'snapd'' failed: E: Sub-process /usr/bin/dpkg returned an error code (1)\n", "stderr": "E: Sub-process /usr/bin/dpkg returned an error code (1)\n", "stdout": "Reading package lists...\nBuilding dependency tree...\nReading state information...\nThe following packages will be REMOVED:\n snapd ubuntu-core-launcher\n0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.\n1 not fully installed or removed.\nAfter this operation, 81.3 MB disk space will be freed.\n(Reading database ... \r(Reading database ... 5%\r(Reading database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\r(Reading database ... 30%\r(Reading database ... 35%\r(Reading database ... 40%\r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\r(Reading database ... 60%\r(Reading database ... 65%\r(Reading database ... 70%\r(Reading database ... 75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading database ... 95%\r(Reading database ... 100%\r(Reading database ... 94629 files and directories currently installed.)\r\nRemoving ubuntu-core-launcher (2.34.2) ...\r\nRemoving snapd (2.34.2) ...\r\nProcessing triggers for man-db (2.7.5-1) ...\r\nSetting up grub-pc (2.02~beta2-36ubuntu3.20) ...\r\ndpkg: error processing package grub-pc (--configure):\r\n subprocess installed post-installation script returned error exit status 1\r\nErrors were encountered while processing:\r\n grub-pc\r\n", "stdout_lines": ["Reading package lists...", "Building dependency tree...", "Reading state information...", "The following packages will be REMOVED:", " snapd ubuntu-core-launcher", "0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.", "1 not fully installed or removed.", "After this operation, 81.3 MB disk space will be freed.", "(Reading database ... ", "(Reading database ... 5%", "(Reading database ... 10%", "(Reading database ... 15%", "(Reading database ... 20%", "(Reading database ... 25%", "(Reading database ... 30%", "(Reading database ... 35%", "(Reading database ... 40%", "(Reading database ... 45%", "(Reading database ... 50%", "(Reading database ... 55%", "(Reading database ... 60%", "(Reading database ... 65%", "(Reading database ... 70%", "(Reading database ... 75%", "(Reading database ... 80%", "(Reading database ... 85%", "(Reading database ... 90%", "(Reading database ... 95%", "(Reading database ... 100%", "(Reading database ... 94629 files and directories currently installed.)", "Removing ubuntu-core-launcher (2.34.2) ...", "Removing snapd (2.34.2) ...", "Processing triggers for man-db (2.7.5-1) ...", "Setting up grub-pc (2.02~beta2-36ubuntu3.20) ...", "dpkg: error processing package grub-pc (--configure):", " subprocess installed post-installation script returned error exit status 1", "Errors were encountered while processing:", " grub-pc"]}
anybody can help ?
using unbuntu 16.04
 
Last edited:

Gnof11

New Member
Joined
Feb 20, 2019
Messages
2
Reaction score
0
any windows guide from zero to fully working? im gettin back from the old days want to make a 8.6 server
 

Merrok

Magic Tomato
Premium User
Joined
Jun 18, 2009
Messages
38
Reaction score
31
Create a system user "otsmanager" with password "otsmanager"
Note that you need to change this immediately after the install.
I have been able to gain access to multiple systems a few days ago using this login information.
All owners have been notified and given time to change their passwords including their MySQL passwords which have been compromised as well.

@Don Daniello You might want to make it more obvious in the first post that people need to change that. Seems like not everyone does.
 
Top