IT/Manuale del Server: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
Line 88: Line 88:
Per avviare il server apri il file '''MTA Server.exe''', e assicurati che sia autorizzato da tutti i firewall e le porte del router.
Per avviare il server apri il file '''MTA Server.exe''', e assicurati che sia autorizzato da tutti i firewall e le porte del router.


==Installing/Updating resources on your server==
==Installare/aggiornare le risorse sul server==
Resources can come in two formats, either a ZIP format or just a normal folder with the script files inside it. The MTA:SA DM server supports both these methods.
Le risorse possono presentarsi in due formati, o un '''archivio .zip''' o semplicemente una '''cartella''' contenente i file dello script. Il server MTA:SA DM supporta entrambi questi formati.


# Move or copy the new resource to your <SERVER>\mods\deathmatch\resources folder.
#Sposta o copia la nuova risorsa nella cartella <syntaxhighlight lang="lua"><SERVER>\mods\deathmatch\resources</syntaxhighlight>.
# In the server window type in the command "refresh" (without the quotes), this will re-scan the resources folder and update the live resources where necessary.
#Avvia da console il comando '''refresh''', questo aggiornerà la lista delle risorse e le risorse in esecuzione dove necessario.


==Uninstalling resources==
==Uninstalling resources==

Revision as of 18:26, 6 June 2008


« Torna alla Pagina principale italiana .

Per iniziare

Avviare un server per giocare in internet o in LAN con i tuoi amici è molto più semplice di quanto sembri: seguendo questa pagina riuscirai a creare il tuo server MTA:SA:DM e renderlo operativo in pochissimo tempo!

Installare il server

L'applicazione per il server è disponibile in numerose versioni a seconda del sistema operativo in cui dovrà girare(Windows, Linux, ecc.).

Linux installation

I installed the server on ubuntu 6.05 LTS. I will add installation instructions for other linux distros at a later time. This install was done on a fresh os install so a few things have to be installed first. First of all ssh into your server using whatever client you like. I prefer putty. Start by typing sudo apt-get upgrade It will prompt you to put your password in again. After the upgrade is done running type sudo apt-get install pico this will install the easy to use pico text editor that you will use to edit the config files. After the install is done running you need to get a copy of libcurl3 for the server to run so type sudo apt-get install libcurl3 Once again it will ask you for your password. Once this is done now we have to get the server program onto your Linux server. There are a few methods for doing this. you can install a ftp server. you can use putty file transfer. If you know someone with a website you can ask them to put the file on their website then use wget http://wwww.websitename.com/file.tar Obviously where website name is change to your friends website. Either way once you have the tar file on your server you need to unpack it you do this by using the command tar -zxvf filename.tar

Installazione su Windows

Installare un server MTA:SA DM su Windows è facilissimo:

  • Scarica qui l'autoinstallante per piattaforma Windows.
  • Installa il server nella cartella che preferisci.

Configurare il server

Iniziamo aprendo il file mtaserver.conf, che si trova nella cartella <SERVER>/mods/deathmatch, usando un qualsiasi editor di testo. Il contenuto del file è autodescrittivo: ogni variabile ha una descrizione su cosa si tratti e come modificare una determinata variabile.

Aggiungere degli admin

Per una spiegazione completa riguardo il file acl.xml (Access Control List) leggi: Access Control List

Per aggiungere degli admins al server:

  • Cerca il file Accounts.xml all'interno della cartella deathmatch ed aprilo.
  • Aggiungi un nuovo account seguendo al sintassi sottostante:
<account name="Nickname" password="Password" />
  • Salva il file.
  • Apri il file acl.xml.
  • Scegli il gruppo di permessi in cui inserire il nuovo account tra Moderator, SuperModerator e Admin.
  • Aggiungi l'account appena creato all'interno del gruppo interessato seguendo la seguente sintassi:
      <object name="resource.Nickname"/>

Alla fine avrai qualcosa di simile a questo:

<group name="Admin">
...
<object name="user.Nickname" />
</group>

Finito! In questo modo puoi aggiungere tutti gli admin che preferisci.

Nota: Per rendere effettive le modifiche a questi file dovrai riavviare il server. Nota 2: Ci sono dei modi per aggiungere e modificare gli accounts anche metre il server è acceso, ad esempio il comando "addaccount <nick> <password>", che permette di aggiungere un account mentre il server è avviato. (Opzione consigliata per i neofiti, o in caso non funzionasse il metodo principale.)

Configurare un web server esterno

Per prestazioni migliori o altri motivi, puoi scegliere di utilizzare un altro server web già funzionante, al posto del server web incorporato. Il server web esterno deve essere accessibile al pubblico, per cui ogni client potrà scaricare il necessario sul proprio computer per giocare sul server.

Al fine di consentire il download di fuori un altro server web, vanno configurate le opzioni httpdownload e httpdownloadurl nel file settings.xml del server:

<httpdownload>1</httpdownload>	
<httpdownloadurl>http://www.mioserver.dom/directory/qui</httpdownloadurl>

Dato che tutte le resources fornite con il server sono compresse, e vengono normalmente estratte dal server incorporato, è necessario permettere ai client di scaricare i file decompressi. I file decompressi sono sempre disponibili nella cartella <SERVER>/mods/deathmatch/resourcecache.

  1. Lancia il server e chiudilo, in questo modo si estrarranno i file nella cartella <SERVER>/mods/deathmatch/resourcecache.
  2. Vai nella cartella sopra descritta e carica i file sul server remoto; può essere fatto in molti modi:
    • Se non ti importa di rendere pubbliche le resources del tuo server: fai semplicemente l'upload dei file contenuti in resourcecache sulla cartella del tuo server remoto.
    • Se non vuoi invece che le tue resources vengano rese pubbliche: vai nella cartella resourcecache e copia manualmente le cartelle sul tuo server, eliminando i file (che non sono necessari per giocare) che non vuoi vengano scaricati.

      Non c'è ancora nessun modo di rendere sicuri i file sul server rapidamente.

Nota: Evita qualsiasi carattere speciale (es. ~, !) negli URL di httpdownloadurl.
Note 2: Non terminare gli URL con degli slash finali (es. hxxp://www.mioserver.dom/directory/ invece di hxxp://www.mioserver.dom/directory)

Avviare il server

Per prima cosa controlla di aver finito di configurare il tuo server, avviare il server è l'ultima cosa, quindi tutto deve già essere pronto!

Per avviare il server apri il file MTA Server.exe, e assicurati che sia autorizzato da tutti i firewall e le porte del router.

Installare/aggiornare le risorse sul server

Le risorse possono presentarsi in due formati, o un archivio .zip o semplicemente una cartella contenente i file dello script. Il server MTA:SA DM supporta entrambi questi formati.

  1. Sposta o copia la nuova risorsa nella cartella
    <SERVER>\mods\deathmatch\resources
    .
  2. Avvia da console il comando refresh, questo aggiornerà la lista delle risorse e le risorse in esecuzione dove necessario.

Uninstalling resources

Resources can easily be removed from your server if you no longer want them.

  1. Delete the ZIP file or the folder of the resource you wish to uninstall
  2. In the server window type in the command "refresh" (without the quotes), this will re-scan the resources folder and update the live resources where necessary.

Administrating your server

You can start resources by typing the command "start resourcename" in the server console, or stop ones with "stop resourcename".

It's also possible to execute these and other admin commands from the ingame console (which you can bring up with the ` key or F8); for this to work, you first need to log in with the command "login username password". Additionally, you can press the p key to bring up the admin panel: this is a graphical interface which allows you to easily kick or ban misbehaving players, among others.

For further commands, type "help" in a console.

Starting a map/gamemode

See the commands section of the documentation for mapmanager for more information.

Remotely administrating your server

This article assumes you have setup a working account with 'Admin' user rights, and have these resources started:

  1. ResourceBrowser
  2. ResourceManager
  3. WebAdmin
  4. WebMap

You're able to access these great remote admin tools by visiting http://<yourserverip>:<httpport>/resourcebrowser in your Firefox. NOTE: Internet Explorer will NOT work, it will not display the resource browser, other browsers (Opera namely) will have mixed results. If you want it to work in Internet Explorer, feel free to recode the resource :)

Useful Notes

  1. You may also update the resources while ingame as long as you have the correct access levels by typing "refresh" in the clients console or "/refresh" in the chat window. This may cause a second of lag if you have many resources.
  2. In the above instructions, <SERVER> is the path to your server's main directory. In most cases this is C:\Program Files\MTA San Andreas\server

Need further help?

Why not pop over to our Forums or join us on IRC (irc.multitheftauto.com #mta - MIRC)