Differences between revisions 78 and 79
Revision 78 as of 2007-08-23 11:01:07
Size: 10483
Editor: KeeganQuinn
Comment: this thing doesn't work anymore.
Revision 79 as of 2007-11-23 18:01:25
Size: 10483
Editor: localhost
Comment: converted to 1.6 markup
Deletions are marked like this. Additions are marked like this.
Line 7: Line 7:
In the future, ["Adhocracy"] will support the functionality which was provided by builder. Until then, check out NewCloneArmyInstallMethodology. In the future, [[Adhocracy]] will support the functionality which was provided by builder. Until then, check out NewCloneArmyInstallMethodology.
Line 169: Line 169:
[[BR]] <<BR>>
Line 173: Line 173:
[[BR]] <<BR>>
Line 195: Line 195:
to setup new accounts from SETUP.sh [[BR]]
# cd /tmp [[BR]]
# wget http://svn.personaltelco.net/svn/ptp/system/trunk/node/auth/SETUP.sh [[BR]]
# VERBOSE=1 sh ./SETUP.sh [[BR]]
to setup new accounts from SETUP.sh <<BR>>
# cd /tmp <<BR>>
# wget http://svn.personaltelco.net/svn/ptp/system/trunk/node/auth/SETUP.sh <<BR>>
# VERBOSE=1 sh ./SETUP.sh <<BR>>

Using builder to create a node

builder is a script which was used to create Personal Telco-branded routers with a captive portal and various other core services on normal computers with two (or more) network interfaces. It was used almost exclusively by the NetworkOperationsTeam.

This project was primarily a simple proof of concept, establishing techniques for effective mass-deployment of nodes. It is no longer functional due to the demise of the original SubversionRepository.

In the future, Adhocracy will support the functionality which was provided by builder. Until then, check out NewCloneArmyInstallMethodology.

Requirements

NOTE - The process documented here WILL NOT WORK. See above.

Please read this entire document before starting your work on a system. This description is not entirely complete, and any comments or suggestions are greatly appreciated.

You'll need the following components:

  • An x86-based (ie., Intel, AMD, Via) PC ("box" or "target") with
    • two (2) or more Ethernet interfaces ("eth0" and "eth1"),
    • a hard disk of at least 1GiB (smaller drives may work, but are not recommended) and
    • at least 16MiB RAM.
    • Usage of this process on embedded systems is not recommended.
  • A temporary working Internet connection connected to one of the Ethernet interfaces during installation. ("source connection")
  • A permanent working Internet connection to be connected to one of the Ethernet interfaces after installation, if installation is not performed on-site. ("target connection")
  • An additional computer of any type running Linux, also connected to the Internet.

Also, you'll need to prepare the following information:

  • a node code: a simple, brief, lowercase, whitespace-free identifier for your new node. For example, the node serving Couch Park has the code 'couchpark'. 12 characters or less recommended; no more than 16.
  • a location name: a short description for your new node. For example, the node serving Couch Park has the location name 'Couch Park'. 16 characters or less recommended; no more than 20.
  • a contact address: a contact e-mail address for your new node. For example, the node serving Couch Park has the contact address 'John Doe <john@hotmail.com>'.

  • a hostname: your box needs a hostname. This can be any reasonably short, lowercase, whitespace-free identifier for the computer. For example, the node serving Couch Park has the hostname 'tinged'. 12 characters or less recommended; no more than 16.

Finally, you'll need the specifics of the target connection:

  • the target connection IP address: you'll need the IP address assigned to the installed target connection.
    • If the address is dynamically assigned, you need to know that this is the case.
    • If the address is static (this is preferred), in addition to the address you will need to know:
      • the target connection network address,
      • the target connection network mask,
      • the target connection broadcast address and
      • the target connection gateway address.
  • the target connection primary DNS server address.
  • the target connection secondary DNS server address.

If you don't already have all of these things, don't begin this process! You won't be able to finish, and it's usually easiest, best and cleanest to go through the entire process at once.

If you're having trouble with the specifics of the target connection, please contact the provider of the connection for more information. They should be able to provide exact values for these fields.

If you're still reading at this point and are not a member of the NetworkOperationsTeam, please consider getting in touch with someone who is and providing to them the information listed above. They will be able to provide you with a working system in a reasonable period of time.

Step One (Base Software)

To begin, you'll need to install the DebianLinux base system on your target box. See DebianLinuxInstallation for detailed information.

Step Two (Registration)

See NodeDb for information on registering with the node database.

See NetworkAddressAllocations to register your network and receive network numbers.

Step Three (Create Configuration Files)

Create files with node-preconfig.sh

1. Create a working directory to run the builder script node-preconfig.sh

  • Do this step outside of the repository tree if you have a local copy of the ptp repository

  • mkdir builder
  • cd builder

2. Get the script from subversion that will do the configuration

3. Prepare the script for execution

  • chmod 755 node-preconfig.sh

4. Install Subversion, if you don't have it. (If "which svn" returns nothing, you don't have it...)

5. Run node-preconfig.sh with the -s option

  • ./node-preconfig.sh -s

6. Complete the following questions in a way that is applicable to your node location

  • [aaronb@laptop builder]$ ./node-preconfig.sh -s
    • Node number: 608 Location (20 char. or less): Urban Grind - Pearl District

      Contact: ops@personaltelco.net Hostname: grank Domain: personaltelco.net FQDN is grank.personaltelco.net Internet IP address (or 'dhcp'): dhcp Internet DNS address 1: 64.122.195.142 Internet DNS address 2 (or 'none'): 198.107.22.251 [replace the secondary with your ISP's primary dns server IP, there needs to be a tertiary designation with these two being added automatically.] PTPnet IP address: 10.11.47.1 PTPnet network address: 10.11.47.0 PTPnet network mask: 255.255.255.0 PTPnet broadcast address: 10.11.47.255 PTPnet DHCP server pool start address: 10.11.47.50 PTPnet DHCP server pool finish address: 10.11.47.200

  • This will create and commit the configuration files for your node into the repository using svn.

Step Four (Make it all come together)

Obtain and run node.sh builder script

These scripts expect to find a computer that has a minimal debian install, two ethernet cards, and a connection to the Internet.

From the command line on the machine that is going to be the captive portal router

  • perform these steps as root in root's home directory.

1. Install wget

  • apt-get install wget

2. Use wget to retreive node.sh

3. Make the script executabe

  • chmod 755 node.sh

4. Run the script

  • ./node.sh [NODEID]
    • example: ./node.sh 608

And now watch it go. When this finishes, reboot the machine. Now you should have a working Personal Telco Captive Portal Machine. This includes all services to provide the network infrastructure at the location. All configuration files are stored and managed in subversion.

Q&A / Commentary

/etc/modules Does not contain the identification of the network drivers which were installed during bf24 installation. You must edit this file to include the driver identification. NOTE It appears that one might look at "svn.personaltelco.net/svn/ptp/system/trunk/node/net/modules-595" as a source of this opportunity as the modules here match what is loaded.

/etc/resolv.conf The nameserver listed/identified does not work and the file must be edited to a working nameserver; HOWEVER even after editing resolv.conf when the system is rebooted, the file reverts to the inoperative nameserver. NOTE It appears that one might look at "svn.personaltelco.net/svn/ptp/system/trunk/node/net/resolv.conf" as the source of the inoperable nameserver.
NOTE This is infact supposed to be using 127.0.0.1 as the nameserver. As bind9 is running locally. If on reboot dns is not working we need to discover why bind isn't producing correct lookups locally. We should not be using external dns nameservers in resolv.conf. AaronBaer
NOTE Check to make sure that the date of the machine in question is synced to an ntp server. I have had sitations where bind9 has stopped working because the host in question has become so far out of sync with the time that bone.personaltelco.net has that it will not resolve hosts. Making sure that ntp is running correctly or using ntpdate to sync time to cornerstone.personaltelco.net and restarting bind has worked on many hosts.

A file download/installation is missing. svn co http://svn.personaltelco.net/svn/ptp/web/trunk home/web CAUTION: Watch when you try this download--as I had to repartition the disk to get the complete file.

EVEN AT THIS POINT Apache fails to start.

- Did your apache failure come from a host name resolution failure? This happened to me. Check out /etc/hosts and make sure it has a correct entry for 127.0.0.1.

More problems from a PTP-supplied Dell Optiplex w/2x NICs: The modules "3c59x" and "eepro100" for the two NICs aren't loaded -- I added

  • insmod 3c59x insmod eepro100

to /etc/init.d/networking. If you are getting "ERROR while getting interface flags: no such device," this may be what you need. Highly recommend that the building scripts go ahead and try to load all reasonably relevant NIC modules, since this is the kind of thing that drives newbies screaming from Debian.

to setup new accounts from SETUP.sh
# cd /tmp
# wget http://svn.personaltelco.net/svn/ptp/system/trunk/node/auth/SETUP.sh
# VERBOSE=1 sh ./SETUP.sh

Authors

AaronBaer, KeeganQuinn


[CategorySoftware] [CategoryPersonalTelco] [CategoryNuCab] [CategoryDocumentation] [CategoryNetwork]

UsingBuilderHowTo (last edited 2012-04-25 13:48:08 by DanRasmussen)