Kronosnet: Difference between revisions

From Alteeve Wiki
Jump to navigation Jump to search
Line 52: Line 52:


<source lang="bash">
<source lang="bash">
vim /etc/pam.d/kronosnet
ln -s /etc/pam.d/system-auth /etc/pam.d/kronosnet
ls -lah /etc/pam.d/kronosnet
</source>
</source>
<source lang="text">
<source lang="text">
#%PAM-1.0
lrwxrwxrwx 1 root root 22 Dec 13 15:27 /etc/pam.d/kronosnet -> /etc/pam.d/system-auth
auth      include password-auth
account    required pam_nologin.so
account    include password-auth
session    include password-auth
</source>
</source>



Revision as of 20:26, 13 December 2010

 AN!Wiki :: Kronosnet

Locate

Install

cd ~
yum -y groupinstall "Development Tools"
yum -y install pam-devel
git clone git://github.com/fabbione/kronosnet
cd kronosnet
./autogen.sh
./configure
make
make install

Create a user and group for kronosnet to run as.

groupadd -r kronosnetadm 
groupmems -g kronosnetadm -a root
### This doesn't add the user to the group for some reason...
useradd kronosnet -b /etc -M -r -s /bin/bash -g kronosnetadm
groupmems -g kronosnetadm -a kronosnet

Set a password for the new kronosnet.

passwd kronosnet
New password: 
Retype new password: 
passwd: all authentication tokens updated successfully.

For the sake of this tutorial, we'll use the password justatest.

Configure

There are two files to create. The first is a pam.d file to control access to kronosnet. The second is the actual kronosnet configuration file.

Create The pam.d Access File

0 lrwxrwxrwx    1 root root    11 Oct 25 13:34 kronosnet -> system-auth
ln -s /etc/pam.d/system-auth /etc/pam.d/kronosnet
ls -lah /etc/pam.d/kronosnet
lrwxrwxrwx 1 root root 22 Dec 13 15:27 /etc/pam.d/kronosnet -> /etc/pam.d/system-auth

Create The kronosnet.conf Configuation File

THIS IS ALL WRONG

The core of kronosnet is configured using the kronosnet.conf configuration file. To understand the example better, we need to define the nodes used.

There are found nodes, each with three network interfaces. These will be used to create the knet interface.

  • an-node03
    • eth0 - 192.168.1.73
    • eth1 - 192.168.2.73
    • eth2 - 192.168.3.73
    • knet0 - 192.168.4.73
  • an-node04
    • eth0 - 192.168.1.74
    • eth1 - 192.168.2.74
    • eth2 - 192.168.3.74
    • knet0 - 192.168.4.74
  • an-node05
    • eth0 - 192.168.1.75
    • eth1 - 192.168.2.75
    • eth2 - 192.168.3.75
    • knet0 - 192.168.4.75
  • an-node06
    • eth0 - 192.168.1.76
    • eth1 - 192.168.2.76
    • eth2 - 192.168.3.76
    • knet0 - 192.168.4.76

Old config deleted.

  • Questions:
    • Confirm: nodename has no need to match any hostname. It is purely a reference withing knet.
    • nodeid: Does this need to be sequential? Must it be a real number?
    • knet_ips: can you have an arbitrary number?
    • knet_mtu: Is 9000 the maximum? What is the default, if any?
    • nodeips: These must match the IPs assigned to existing NICs, I assume?
    • inet: What is this for? Over-ridding the TAP name?
    • preup, up, down and postdown: Are these hooks to trigger scripts when <event> happens to the knet interface?
    • When this config file changes, how is best to load in the new config?

Run the Daemon

There is currently no init.d script for kronosnetd, so it will need to be started manually.

Must run os 'root'.

kronosnetd

There is no output from that command, and it will daemonized and return you to the shell. You can check that it is running with ps.

Network Setup

In this tutorial, we'll use four nodes, each with three network cards.

  • an-node03
  • an-node04
  • an-node05
  • an-node06

To log in for the first time, use telnet to connect to the localhost on TCP port 50000.

telnet localhost 50000
Trying ::1...
Connected to localhost.
Escape character is '^]'.
Welcome to kronosnetd 0.1 (built Nov 28 2010 13:32:00)

login:

At this point, you can login using the kronostnet user name and justatest password. Once logged in successfully, you should see the knet prompt.

login:kronosnet
Password: 

Welcome kronosnet (::1) on vty(0)

knet#

To quit at any time, simply enter the telnet escape code. This is usually ^] (<ctrl> + ])

  • 8 links per node
  • 2^16 (64,000) nodes
  • git checkout 10a377ff02f98b1858009cc9bde55b75e4e5d21e

 

Any questions, feedback, advice, complaints or meanderings are welcome.
Alteeve's Niche! Enterprise Support:
Alteeve Support
Community Support
© Alteeve's Niche! Inc. 1997-2024   Anvil! "Intelligent Availability®" Platform
legal stuff: All info is provided "As-Is". Do not use anything here unless you are willing and able to take responsibility for your own actions.