特殊:Badtitle/NS100:SettingUpJabberServer:修订间差异
小无编辑摘要 |
小无编辑摘要 |
||
第1行: | 第1行: | ||
{{From|https://help.ubuntu.com/community/SettingUpJabberServer}} | {{From|https://help.ubuntu.com/community/SettingUpJabberServer}} | ||
{{Languages|UbuntuHelp:SettingUpJabberServer}} | {{Languages|UbuntuHelp:SettingUpJabberServer}} | ||
<<Include(Tag/Unsupported)>> | |||
This is an easy howto to setup a Jabber server on Ubuntu Linux. For more info browse the official guide on [http://jabberd.jabberstudio.org/1.4/doc/adminguide]. | This is an easy howto to setup a Jabber server on Ubuntu Linux. For more info browse the official guide on [http://jabberd.jabberstudio.org/1.4/doc/adminguide]. | ||
==== Why running your own Jabber Server? ==== | ==== Why running your own Jabber Server? ==== | ||
第125行: | 第126行: | ||
</nowiki></pre> | </nowiki></pre> | ||
If these ports are "LISTEN"ing it's all right. | If these ports are "LISTEN"ing it's all right. | ||
[[category:UbuntuHelp]] | [[category:UbuntuHelp]] |
2010年5月20日 (四) 00:11的最新版本
文章出处: |
{{#if: | {{{2}}} | https://help.ubuntu.com/community/SettingUpJabberServer }} |
点击翻译: |
English {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/af | • {{#if: UbuntuHelp:SettingUpJabberServer|Afrikaans| [[::SettingUpJabberServer/af|Afrikaans]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ar | • {{#if: UbuntuHelp:SettingUpJabberServer|العربية| [[::SettingUpJabberServer/ar|العربية]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/az | • {{#if: UbuntuHelp:SettingUpJabberServer|azərbaycanca| [[::SettingUpJabberServer/az|azərbaycanca]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/bcc | • {{#if: UbuntuHelp:SettingUpJabberServer|جهلسری بلوچی| [[::SettingUpJabberServer/bcc|جهلسری بلوچی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/bg | • {{#if: UbuntuHelp:SettingUpJabberServer|български| [[::SettingUpJabberServer/bg|български]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/br | • {{#if: UbuntuHelp:SettingUpJabberServer|brezhoneg| [[::SettingUpJabberServer/br|brezhoneg]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ca | • {{#if: UbuntuHelp:SettingUpJabberServer|català| [[::SettingUpJabberServer/ca|català]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/cs | • {{#if: UbuntuHelp:SettingUpJabberServer|čeština| [[::SettingUpJabberServer/cs|čeština]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/de | • {{#if: UbuntuHelp:SettingUpJabberServer|Deutsch| [[::SettingUpJabberServer/de|Deutsch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/el | • {{#if: UbuntuHelp:SettingUpJabberServer|Ελληνικά| [[::SettingUpJabberServer/el|Ελληνικά]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/es | • {{#if: UbuntuHelp:SettingUpJabberServer|español| [[::SettingUpJabberServer/es|español]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/fa | • {{#if: UbuntuHelp:SettingUpJabberServer|فارسی| [[::SettingUpJabberServer/fa|فارسی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/fi | • {{#if: UbuntuHelp:SettingUpJabberServer|suomi| [[::SettingUpJabberServer/fi|suomi]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/fr | • {{#if: UbuntuHelp:SettingUpJabberServer|français| [[::SettingUpJabberServer/fr|français]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/gu | • {{#if: UbuntuHelp:SettingUpJabberServer|ગુજરાતી| [[::SettingUpJabberServer/gu|ગુજરાતી]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/he | • {{#if: UbuntuHelp:SettingUpJabberServer|עברית| [[::SettingUpJabberServer/he|עברית]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/hu | • {{#if: UbuntuHelp:SettingUpJabberServer|magyar| [[::SettingUpJabberServer/hu|magyar]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/id | • {{#if: UbuntuHelp:SettingUpJabberServer|Bahasa Indonesia| [[::SettingUpJabberServer/id|Bahasa Indonesia]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/it | • {{#if: UbuntuHelp:SettingUpJabberServer|italiano| [[::SettingUpJabberServer/it|italiano]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ja | • {{#if: UbuntuHelp:SettingUpJabberServer|日本語| [[::SettingUpJabberServer/ja|日本語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ko | • {{#if: UbuntuHelp:SettingUpJabberServer|한국어| [[::SettingUpJabberServer/ko|한국어]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ksh | • {{#if: UbuntuHelp:SettingUpJabberServer|Ripoarisch| [[::SettingUpJabberServer/ksh|Ripoarisch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/mr | • {{#if: UbuntuHelp:SettingUpJabberServer|मराठी| [[::SettingUpJabberServer/mr|मराठी]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ms | • {{#if: UbuntuHelp:SettingUpJabberServer|Bahasa Melayu| [[::SettingUpJabberServer/ms|Bahasa Melayu]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/nl | • {{#if: UbuntuHelp:SettingUpJabberServer|Nederlands| [[::SettingUpJabberServer/nl|Nederlands]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/no | • {{#if: UbuntuHelp:SettingUpJabberServer|norsk| [[::SettingUpJabberServer/no|norsk]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/oc | • {{#if: UbuntuHelp:SettingUpJabberServer|occitan| [[::SettingUpJabberServer/oc|occitan]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/pl | • {{#if: UbuntuHelp:SettingUpJabberServer|polski| [[::SettingUpJabberServer/pl|polski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/pt | • {{#if: UbuntuHelp:SettingUpJabberServer|português| [[::SettingUpJabberServer/pt|português]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ro | • {{#if: UbuntuHelp:SettingUpJabberServer|română| [[::SettingUpJabberServer/ro|română]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/ru | • {{#if: UbuntuHelp:SettingUpJabberServer|русский| [[::SettingUpJabberServer/ru|русский]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/si | • {{#if: UbuntuHelp:SettingUpJabberServer|සිංහල| [[::SettingUpJabberServer/si|සිංහල]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/sq | • {{#if: UbuntuHelp:SettingUpJabberServer|shqip| [[::SettingUpJabberServer/sq|shqip]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/sr | • {{#if: UbuntuHelp:SettingUpJabberServer|српски / srpski| [[::SettingUpJabberServer/sr|српски / srpski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/sv | • {{#if: UbuntuHelp:SettingUpJabberServer|svenska| [[::SettingUpJabberServer/sv|svenska]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/th | • {{#if: UbuntuHelp:SettingUpJabberServer|ไทย| [[::SettingUpJabberServer/th|ไทย]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/tr | • {{#if: UbuntuHelp:SettingUpJabberServer|Türkçe| [[::SettingUpJabberServer/tr|Türkçe]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/vi | • {{#if: UbuntuHelp:SettingUpJabberServer|Tiếng Việt| [[::SettingUpJabberServer/vi|Tiếng Việt]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/yue | • {{#if: UbuntuHelp:SettingUpJabberServer|粵語| [[::SettingUpJabberServer/yue|粵語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/zh | • {{#if: UbuntuHelp:SettingUpJabberServer|中文| [[::SettingUpJabberServer/zh|中文]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/zh-hans | • {{#if: UbuntuHelp:SettingUpJabberServer|中文(简体)| [[::SettingUpJabberServer/zh-hans|中文(简体)]]}}|}} {{#ifexist: {{#if: UbuntuHelp:SettingUpJabberServer | UbuntuHelp:SettingUpJabberServer | {{#if: | :}}SettingUpJabberServer}}/zh-hant | • {{#if: UbuntuHelp:SettingUpJabberServer|中文(繁體)| [[::SettingUpJabberServer/zh-hant|中文(繁體)]]}}|}} |
{{#ifeq:UbuntuHelp:SettingUpJabberServer|:SettingUpJabberServer|请不要直接编辑翻译本页,本页将定期与来源同步。}} |
{{#ifexist: :SettingUpJabberServer/zh | | {{#ifexist: SettingUpJabberServer/zh | | {{#ifeq: {{#titleparts:SettingUpJabberServer|1|-1|}} | zh | | }} }} }} {{#ifeq: {{#titleparts:SettingUpJabberServer|1|-1|}} | zh | | }}
<<Include(Tag/Unsupported)>> This is an easy howto to setup a Jabber server on Ubuntu Linux. For more info browse the official guide on [1].
Why running your own Jabber Server?
Many people love IM (Instant Messaging) and many of these should run their own server. Jabber is an XML based cross platform chat and messenging server which is freely available. It runs on Linux, Solaris, and many other Unix variants. For a small office or a collection of offices it's a great way to allow people to chat without resorting to outside services such as MSN, Yahoo, Icq. The beauty of this distributed system is in its flexibility: anyone can set up a Jabber server and use it however they wish. It can be used in a closed "environment" or it can join the growing worldwide network.
Required packages
In Hoary the easy way to obtain a Jabber server is run
sudo apt-get install jabber
done. On server side, you should do common operations for system daemons:
# Stop the server sudo /etc/init.d/jabber stop # Start the server sudo /etc/init.d/jabber start # Restart the server sudo /etc/init.d/jabber restart
If you need additional "transport" to other IM you should install the following:
jabber-aim - Provides AIM messenger transport for Jabber IM server jabber-jit - Jabber ICQ Transport jabber-msn - Provides the MSN transport for the Jabber IM server jabber-yahoo - Provides Yahoo messenger transport for Jabber IM server
or check yourself what kind of packages are related to jabber
:
apt-cache search jabber
Basic configuration
For a very basic configuration you should look at /etc/jabber/jabber.cfg
file where you'll find something like that:
JABBER_HOSTNAME=localhost JABBER_SPOOL=/var/lib/jabber
Where the JABBER_HOSTNAME
is the running server hostname ("localhost" by default), and JABBER_SPOOL
is the "spool" directory where temporary file are stored. These variables are then passed to jabberd in the -h
switch.
In small "environments" you should have a running DNS system and it is useful to setup your IM hostname. For example, if your hostname is "jabber.mydomain" the resulting jabber.cfg
will be:
JABBER_HOSTNAME=jabber.mydomain
Advanced configuration
For advanced configuration you should look at /etc/jabber/jabber.xml
file where are all the setting for your Jabber Server, well commented. Appart the hostname note, the default settings should be right for almost server implementations.
Scripts:
- 1: Sample for Yahoo-Transport
<jabber> <service id="yahoo-linker"> <connect> <ip></ip> <port></port> <secret></secret> </connect> <uplink/> </service> <pidfile>./yahoo-jabber.pid</pidfile> <service id="yahoo.example.com"> <load><yahoo_transport>/path/to/yahoo-transport.so</yahoo_transport></load> <config xmlns="jabber:config:yahoo"> <vCard> <NAME>Yahoo Transport</NAME> </vCard> <server>scs.yahoo.com</server> <port>5050</port> <charmap>CP1252</charmap> </config> </service> </jabber>
Controlling user accounts
If you want to control the registration process are needed some changes in the configuration file. You can disable registrations commenting out certain sections, for e.g. the <register>
and the <mod_register>
tags, which are in different parts of the file.
<register notify="yes"> <instructions> Choose a username and password to register with this server. <instructions> <name/> <email/> <register>
and
<mod_register>./jsm/jsm.so</mod_register>
Disabling registration, you need to create the user accounts manually.
Conference
With the conference service you have group chat rooms, either public or private. Fot that you need to install jabber-jud
with the command sudo apt-get install jabber-jud
. After that edit the jabber.xml
configuration file and add something like that:
<browse> <conference type="private" jid="conference.localhost" name="Private Conferencing"/> </browse>
to restrict access to the rooms to local account holders (example) and the following code:
<service id='conference.localhost'> <load><conference>/usr/lib/jabber/conference.so</conference></load> <conference xmlns="jabber:config:conference"> <private/> <history>30</history> <vCard> <FN>Private Conferences</FN> <DESC>This service is for private conferencing rooms.</DESC> <URL>http://foo.bar/</URL> </vCard> <notice> <join> has joined</join> <leave> has left</leave> <rename> is now known as </rename> </notice> </conference> </service>
Restart the server and log in again. You will be able to show Private Conferencing and create a conference room. You can then invite others to join in the conference room.
Tips
Connecting to the server with your client appear this message "There was an error authenticating with jabber server. Details: Unauthorized"
? Many references say that this is due to SSL directive: you need to set your IP with <ssl port='5223'>
and restart the server.
To test the connection try this:
sudo netstat -an | grep -E '5222|5269'
If these ports are "LISTEN"ing it's all right.