Precautions for Erlang distributed linux and windows systems
Source: Internet
Author: User
Erlang distributed issues that should be paid attention to between linux and windows systems-Linux Enterprise Application-Linux server application information. The following is a detailed description. If nothing happens, test Erlang distribution between two machines. One is Windows XP, and the other is redHat9. Without detailed documents, you can find it and record it.
1. First, the implementation of distributed Erlang provides its own security mechanism to prevent unauthorized access to the Erlang system. The Erlang system must have the same magic cookie when interacting with other machines. erlang. in the cookie file, you need to edit one copy to test between two different machines. erlang. cookie, the content is casual, such:
Just_test
Then copy the file to the directory where the windows environment variable HOMEPATH is located, for example, my files are C: \ Documents and Settings \ Admin, and linux copies them to the directory pointed to by the environment variable $ HOME, for example, I am/root. Note that the. erlang. cookie file in linux needs to be set to-r --------, that is, 400, which is only readable by the Owner:
Chmod 400. erlang. cookie
2. because the node name in Erlang is name @ host and host is computer name, you must add the computer name and ip address to the hosts file on both machines, this file is in/etc/hosts in linux. You can use vi to edit it as follows:
127.0.0.1 localhost
X. x zane # ip address and computer name of the windows Server
Hosts is in the C: \ windows \ system32 \ drivers \ etc directory of the WINDOWS system. Edit:
127.0.0.1 localhost
X. x dennis # Name and ip address of the linux machine
3. Step 3: Start the node by running the erl-sname or erl-name command. Before that, start the epmd process, which maps the symbol name to the machine address.
Run the following command on both machines:
Epmd-daemon
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.