Multicast Deploy problem (FOG 1.2.0) #!im
-
Okay, what steps do I follow to upgrade or do I need a fresh install?
-
@emijoa You can upgrade depending on the OS you’re using. You’ll be installing what’s called FOG Trunk.
It works best on CentOS 7, Fedora 21+, and works ok on Ubuntu 14+ and Debian 8.
Here are the instructions, just pick a method:
https://wiki.fogproject.org/wiki/index.php?title=Upgrade_to_trunkI would advise you and everyone else to always backup their DB and Hosts via the instructions at the bottom of that article - not because I expect anything to break, but because it’s simply good practice to have backups of your data.
-
I tried updating using git earlier today, it failed when trying to start my-sql.
-
@emijoa What OS are you running?
-
Ubuntu 14.04.3, installed LAMP and SSH. Also installed a Minimal Gnome Core Desktop
-
@emijoa Ok. if you look inside of
/var/log/
you’ll see some files calledfog_error_<version>.log
The version you tried installing earlier will have an error log with a corresponding version number in the name.
If you can post the last few lines in that file, that will help figure out why the installation failed.
Basically, all error output from the installer is redirected to that log.
-
Okay:
* Stopping FOG Computer Imaging Solution: FOGMulticastManager start-stop-daemon: warning: failed to kill 1189: No such process ...done. * Stopping FOG Computer Imaging Solution: FOGImageReplicator start-stop-daemon: warning: failed to kill 1128: No such process ...done. ../lib/common/functions.sh: line 658: /etc/init.d/FOGSnapinReplicator: No such file or directory * Stopping FOG Computer Imaging Solution: FOGScheduler start-stop-daemon: warning: failed to kill 1215: No such process ...done. ../lib/common/functions.sh: line 658: /etc/init.d/FOGPingHosts: No such file or directory stop: Unknown job: mysql start: Unknown job: mysql
For the whole file:
https://db.tt/8lgK4hAM -
@emijoa Try to run the installer with sudo.
sudo ./installfog.sh
-
Okay, that did the work, but now it stops at dhcp. Also, when i look in the dhcp they seem to have been changed.
* Stopping ISC DHCP server dhcpd ...fail! dhcpd self-test failed. Please fix /etc/dhcp/dhcpd.conf. The error was: Internet Systems Consortium DHCP Server 4.2.4 Copyright 2004-2012 Internet Systems Consortium. All rights reserved. For info, please visit https://www.isc.org/software/dhcp/ /etc/dhcp/dhcpd.conf line 35: expecting numeric value. subnet 0.0.0.0 netmask { ^ /etc/dhcp/dhcpd.conf line 37: range declaration not allowed here. range ^ /etc/dhcp/dhcpd.conf line 42: expecting a declaration filename "undionly.kpxe"; ^ Configuration file errors encountered -- exiting
-
@emijoa For some reason, the installer can’t detect your subnet mask, and there might be other issues as well.
What interface does the installer suggest?
Please post the output ofip addr
And post the output ofcat /etc/dhcp/dhcpd.conf
-
root@ubuntu-fog:/fog_git/bin# cat /etc/dhcp/dhcpd.conf DHCP Server Configuration file see /usr/share/doc/dhcp*/dhcpd.conf.sample This file was created by FOG Definition of PXE-specific options Code 1: Multicast IP Address of bootfile Code 2: UDP Port that client should monitor for MTFTP Responses Code 3: UDP Port that MTFTP servers are using to listen for MTFTP requests Code 4: Number of seconds a client must listen for activity before trying to start a new MTFTP transfer Code 5: Number of seconds a client must listen before trying to restart a MTFTP transfer option space PXE; option PXE.mtftp-ip code 1 = ip-address; option PXE.mtftp-cport code 2 = unsigned integer 16; option PXE.mtftp-sport code 3 = unsigned integer 16; option PXE.mtftp-tmout code 4 = unsigned integer 8; option PXE.mtftp-delay code 5 = unsigned integer 8; option arch code 93 = unsigned integer 16; # RFC4578 use-host-decl-names on; ddns-update-style interim; ignore client-updates; next-server 192.168.1.101; Specify subnet of ether device you do NOT want service. for systems with two or more ethernet devices. subnet 136.165.0.0 netmask 255.255.0.0 {} subnet 0.0.0.0 netmask { option subnet-mask ; range dynamic-bootp 0.0.0.10 192.168.1.254; default-lease-time 21600; max-lease-time 43200; option domain-name-servers x.x.x.x; option routers x.x.x.x; filename "undionly.kpxe"; }
root@ubuntu-fog:/fog_git/bin# ip addr 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000 link/ether 00:25:b3:11:ea:3d brd ff:ff:ff:ff:ff:ff inet 192.168.1.101/24 brd 192.168.1.255 scope global eth0 valid_lft forever preferred_lft forever inet6 fe80::225:b3ff:fe11:ea3d/64 scope link valid_lft forever preferred_lft forever
Here’s is also the fog settings, if that is interesting.
root@ubuntu-fog:/fog_git/bin# cat /opt/fog/.fogsettings Created by the FOG Installer Version: 1.2.0 Install time: Tue 05 Jan 2016 11:20:32 PM CET ipaddress="192.168.1.101"; interface="eth0"; routeraddress="# option routers x.x.x.x;"; plainrouter=""; dnsaddress="# option domain-name-servers x.x.x.x; "; dnsbootimage=""; password="69f422"; osid="2"; osname="Debian"; dodhcp="y"; bldhcp="1"; installtype="N"; snmysqluser="root" snmysqlpass=""; snmysqlhost="localhost"; installlang="0"; donate="0"; fogupdateloaded="1"
-
@emijoa said:
192.168.1.101/24
With an address and subnet mask like that, I’m wondering if you don’t already have DHCP running on some device in your network already?
What is the output of
route -n
What is the output ofcat /etc/resolv.conf
-
No, it was at first a misspell, but i didn’t change it as it was only a test server. I’ve been reinstalling a few times already.
root@ubuntu-fog:/fog_git/bin# route -n Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 eth0 192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
root@ubuntu-fog:/fog_git/bin# cat /etc/resolv.conf Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8) DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN nameserver 192.168.1.1
The tutorial I followed wanted me to set static in this file.
root@ubuntu-fog:/fog_git/bin# cat /etc/network/interfaces This file describes the network interfaces available on your system and how to activate them. For more information, see interfaces(5). The loopback network interface auto lo iface lo inet loopback The primary network interface auto eth0 iface eth0 inet static address 192.168.1.101 netmask 255.255.255.0 gateway 192.168.1.1 dns-nameservers 192.168.1.1
-
@emijoa Ok so inside of
/opt/fog/.fogsettings
change thebldhcp="1";
setting tobldhcp="0";
and save that,and then remove everthing in the /etc/dhcp/dhcpd.conf file and then put the below config in there and save, then try to restart dhcp with
service dhcpd stop;service dhcpd start
The below config has your fog server’s address reserved, and it’s setup to handle multiple host architectures.
This doesn’t fix why the subnet and mask weren’t detected right though… and because the subnet was detected as 0.0.0.0, that’s why it set the starting rage to 0.0.0.10.
After you’ve got the below file in place and the .fogsettings modified and dhcp restarted, try to run the installer again (as sudo) and see what happens.
@Tom-Elliott the good news is it detected the broadcast address accurately and setup the ending range correctly. I’ve been working on an enhanced way of detecting the IP address, and a better method of calculating the network address (based on binary math)… so that change will eventually come.
option space PXE; option PXE.mtftp-ip code 1 = ip-address; option PXE.mtftp-cport code 2 = unsigned integer 16; option PXE.mtftp-sport code 3 = unsigned integer 16; option PXE.mtftp-tmout code 4 = unsigned integer 8; option PXE.mtftp-delay code 5 = unsigned integer 8; option arch code 93 = unsigned integer 16; # RFC4578 use-host-decl-names on; ddns-update-style interim; ignore client-updates; next-server 192.168.1.101; authoritative; subnet 192.168.1.0 netmask 255.255.255.0 { option subnet-mask 255.255.255.0; range dynamic-bootp 192.168.1.0 192.168.1.254; default-lease-time 21600; max-lease-time 43200; option domain-name-servers 192.168.1.1; option routers 192.168.1.1; class "UEFI-32-1" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00006"; filename "i386-efi/ipxe.efi"; } class "UEFI-32-2" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00002"; filename "i386-efi/ipxe.efi"; } class "UEFI-64-1" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00007"; filename "ipxe.efi"; } class "UEFI-64-2" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00008"; filename "ipxe.efi"; } class "UEFI-64-3" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00009"; filename "ipxe.efi"; } class "Legacy" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00000"; filename "undionly.kkpxe"; } } host fog-server { hardware ethernet 00:25:b3:11:ea:3d; fixed-address 192.168.1.101; }
-
There is no service that is called dhcpd, however there is one called isc-dhcp-server, I believe this was installed by the 1.2.0 installer?
root@ubuntu-fog:/fog_git/bin# service --help Usage: service < option > | --status-all | [ service_name [ command | --full-restart ] ] root@ubuntu-fog:/fog_git/bin# service --status-all [ ? ] FOGImageReplicator [ ? ] FOGMulticastManager [ ? ] FOGScheduler [ + ] acpid [ - ] anacron [ + ] apache2 [ + ] apparmor [ ? ] apport [ + ] atd [ + ] avahi-daemon [ + ] bluetooth [ + ] clamav-freshclam [ ? ] console-setup [ + ] cron [ + ] cups [ + ] cups-browsed [ - ] dbus [ ? ] dns-clean [ + ] friendly-recovery [ - ] gdm [ - ] grub-common [ ? ] irqbalance [ - ] isc-dhcp-server [ ? ] killprocs [ ? ] kmod [ ? ] mysql [ ? ] networking [ + ] nfs-kernel-server [ ? ] ondemand [ - ] php5-fpm [ ? ] pppd-dns [ - ] procps [ - ] pulseaudio [ ? ] rc.local [ + ] resolvconf [ + ] rpcbind [ - ] rsync [ + ] rsyslog [ + ] saned [ ? ] screen-cleanup [ ? ] sendsigs [ - ] ssh [ - ] sudo [ + ] tftpd-hpa [ + ] udev [ ? ] umountfs [ ? ] umountnfs.sh [ ? ] umountroot [ - ] unattended-upgrades [ - ] urandom [ - ] x11-common [ + ] xinetd
It came with this message
root@ubuntu-fog:/home/administrator# sudo service isc-dhcp-server stop stop: Unknown instance: root@ubuntu-fog:/home/administrator# sudo service isc-dhcp-server start isc-dhcp-server start/running, process 7787
(I’ve been restarting this service whenever I changed the bootfile for testing.)
I ran the ./installfog.sh and it went through smoothly.
Logfile:
https://dl.dropboxusercontent.com/u/106805228/fog_error_5937.logI’ll test and see if something is different on the clients tomorrow. Currently writing this from home.
-
@emijoa said:
There is no service that is called dhcpd, however there is one called isc-dhcp-server
I’m a Red-Hat kind of guy, and I do not apologize.
Do keep us updated on how it goes.
-
Will do! I’m new to Linux in general, I’ve tried a little ubuntu and debian. But I did ubuntu as it seemed to be the best documentet on the wiki
What os would you recommend to run fog on ?
-
-
@Wayne-Workman said:
@emijoa said:
What os would you recommend to run fog on ?
CentOS 7
I might give that a go then the next time I reinstall.
-
Hey, I’ve tested the client today.
At first the client would boot on network, get ip adress, try configure net0 be successful then end with dhcp failed. It then guides me to this page:
http://ipxe.org/err/040ee1
And I runifconf -c dhcp net0
Then the message says “Connection timed out” and guide me to:
http://ipxe.org/err/4c1060
Then i tried booting on an older client hp compaq 6735b and this one boots up alright.So I changed in dhcpd.conf
class "Legacy" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00000"; filename "undionly.kkpxe";
to
class "Legacy" { match if substring(option vendor-class-identifier, 0, 20) = "PXEClient:Arch:00000"; filename "ipxe.kkpxe";
Then the newer client would boot, (in boot it first failed at configuring net0, 00:00:00:00:00, then it tried configuring net1, this was a legit address.)and i tried multicast, then it would complete the first setup and boot partclone, in partclone it says “Starting to restore image (-) to device (/dev/sda1)”, it stop at this window. After checking the server webgui, i saw that the image i was trying to download (i uploaded it at some point from a different computer) stood with 0B, i did a new upload and then it says 465GB, checking the disk with df -h:
root@ubuntu-fog:/etc/dhcp# df -h Filesystem Size Used Avail Use% Mounted on udev 2.8G 4.0K 2.8G 1% /dev tmpfs 566M 1.2M 565M 1% /run /dev/mapper/ubuntu--fog--vg-root 105G 21G 79G 21% / none 4.0K 0 4.0K 0% /sys/fs/cgroup none 5.0M 0 5.0M 0% /run/lock none 2.8G 148K 2.8G 1% /run/shm none 100M 24K 100M 1% /run/user /dev/sda1 236M 41M 183M 19% /boot
Tried again to multicast, but stops at same window in partclone.