@arnaudrigole said:
its not very practical to define this parameter to the 500 hosts 1 by 1 ^^’ … we will see.
That’s what groups are for.
@arnaudrigole said:
its not very practical to define this parameter to the 500 hosts 1 by 1 ^^’ … we will see.
That’s what groups are for.
@Thiago You probably can by editing the various small text files in the image’s folder. I would strongly recommend making backups of these files before you change them.
Since the feedback has been positive, I’ve cross-linked the old ‘upgrade to trunk’ and ‘getting fog’ articles. I also ask that when people request instructions on getting fog installed, we reference the newer ‘getting fog’ article.
Just posting what I’ve worked on this weekend. This is not finished, the backend-script is not CRON ready yet and there is no installer yet either.

FOGFileChecksum.php
<?php
$servername="localhost";
$username="wayne";
$password="";
$database="fog";
// Create connection
$link = new mysqli($servername, $username, $password, $database);
// Check connection
if ($link->connect_error) {
// Couldn't establish a connection with the database.
die($SiteErrorMessage);
}
$fileLocation = array("");
$fileSum = array("");
$sql = "select DISTINCT(fileSum),fileLocation from fileChecksums order by fileLocation";
$result1 = $link->query($sql);
while($row1 = $result1->fetch_assoc()) {
$aSum = $row1['fileSum'];
$aLocation = $row1['fileLocation'];
array_push($fileSum, $aSum);
array_push($fileLocation, $aLocation);
}
$arrlength = count($fileLocation);
echo "The below table only shows detected changes in a file.<br><p>";
echo "New files and files that have not been changed since creation are not listed. There is no consideration for storage groups or when images were uploaded.<br>";
echo "If a change in a file is detected, a set of relevant records from all storage nodes concerning the file are displayed.<br><p>";
echo "You should see changes in files when an image is updated, when snapin files are updated, or when replication does not occur for a updated image or snapin, or when the storage node's hardware (hdd mostly) is failing.<br><p>";
echo "<table border=\"1\" style=\"width:100%\">";
echo "<tr>";
echo "<td>Hash Checksum</td>";
echo "<td>When this record was recorded</td>";
echo "<td>Host</td>";
echo "<td>File</td>";
echo "</tr>";
for($x = 1; $x < $arrlength; $x++) {
if ($fileLocation[$x-1] == $fileLocation[$x]) {
$sql = "select distinct(fileSum),fileLocation,fileHost from fileChecksums where fileLocation = '$fileLocation[$x]'";
$result1 = $link->query($sql);
while($row1 = $result1->fetch_assoc()) {
$aSum = $row1['fileSum'];
$aLocation = $row1['fileLocation'];
$aHost = $row1['fileHost'];
$sql = "select * from fileChecksums where fileLocation = '$aLocation' and fileHost = '$aHost' and fileSum = '$aSum' order by fileTime ASC LIMIT 1";
$result2 = $link->query($sql);
while($row2 = $result2->fetch_assoc()) {
$aSum = $row2['fileSum'];
$aLocation = $row2['fileLocation'];
$aHost = $row2['fileHost'];
$aTime = $row2['fileTime'];
$aTime = gmdate("l jS \of F Y h:i:s A", $aTime);
echo "<tr>";
echo "<td>$aSum</td>";
echo "<td>$aTime</td>";
echo "<td>$aHost</td>";
echo "<td>$aLocation</td>";
echo "</tr>";
}
}
}
}
echo "</table>";
$link->close();
?>
FOGFileChecksum.sh
#-----Variables-----#
files=/root/files.txt
fogsettings=/opt/fog/.fogsettings
ipaddress="$(grep 'ipaddress=' $fogsettings | cut -d \' -f2 )"
snmysqluser="$(grep 'snmysqluser=' $fogsettings | cut -d \' -f2 )"
snmysqlpass="$(grep 'snmysqlpass=' $fogsettings | cut -d \' -f2 )"
snmysqlhost="$(grep 'snmysqlhost=' $fogsettings | cut -d \' -f2 )"
#-----Connect to mysql and querry all nodes that have the IP-----#
if [[ $snmysqlhost != "" ]]; then
imagePaths=$(mysql -s -h$snmysqlhost -u$snmysqluser -p$snmysqlpass -D fog -e "SELECT ngmRootPath FROM nfsGroupMembers WHERE ngmHostname = '$ipaddress' ORDER BY ngmID")
snapinPaths=$(mysql -s -h$snmysqlhost -u$snmysqluser -p$snmysqlpass -D fog -e "SELECT ngmSnapinPath FROM nfsGroupMembers WHERE ngmHostname = '$ipaddress' ORDER BY ngmID")
elif [[ $snmysqlpass != "" ]]; then
imagePaths=$(mysql -s -u$snmysqluser -p$snmysqlpass -D fog -e "SELECT ngmRootPath FROM nfsGroupMembers WHERE ngmHostname = '$ipaddress' ORDER BY ngmID")
snapinPaths=$(mysql -s -u$snmysqluser -p$snmysqlpass -D fog -e "SELECT ngmSnapinPath FROM nfsGroupMembers WHERE ngmHostname = '$ipaddress' ORDER BY ngmID")
else
imagePaths=$(mysql -s -D fog -e "SELECT ngmRootPath FROM nfsGroupMembers WHERE ngmHostname = '$ipaddress' ORDER BY ngmID")
snapinPaths=$(mysql -s -D fog -e "SELECT ngmSnapinPath FROM nfsGroupMembers WHERE ngmHostname = '$ipaddress' ORDER BY ngmID")
fi
#-----Find all files on all local storage nodes-----#
if [[ -e $files ]]; then
rm -f $files
fi
for i in ${imagePaths[@]}; do
find ${i} -type f >> $files
done
for i in ${snapinPaths[@]}; do
find ${i} -type f >> $files
done
IFS=$'\n' read -d '' -r -a allFiles < $files
#-----Checksum all files, insert into database-----#
for i in ${allFiles[@]}; do
md5sum_space_file_space_time="$(sha1sum ${i}) $(date +%s)"
N=1
fileSum=$(echo $md5sum_space_file_space_time | awk -v N=$N '{print $N}')
N=2
fileLocation=$(echo $md5sum_space_file_space_time | awk -v N=$N '{print $N}')
N=3
fileTime=$(echo $md5sum_space_file_space_time | awk -v N=$N '{print $N}')
if [[ $snmysqlhost != "" ]]; then
mysql -s -h$snmysqlhost -u$snmysqluser -p$snmysqlpass -D fog -e "INSERT INTO fileChecksums (fileHost,fileTime,fileSum,fileLocation) VALUES ('$ipaddress','$fileTime','$fileSum','$fileLocation')"
else
mysql -s -D fog -e "INSERT INTO fileChecksums (fileHost,fileTime,fileSum,fileLocation) VALUES ('$ipaddress','$fileTime','$fileSum','$fileLocation')"
fi
done
FOGFileChecksum.sql
USE fog
CREATE TABLE fileChecksums(
fileChecksumsID int NOT NULL AUTO_INCREMENT,
fileHost VARCHAR(255) NOT NULL,
fileTime int NOT NULL,
fileSum VARCHAR(40) NOT NULL,
fileLocation VARCHAR(255) NOT NULL,
PRIMARY KEY (fileChecksumsID)
);
@andyroo54 I agree, the default maximum should be bigger. I’d opt for 512MB or 1GB.
@tito026 Yo recomendaría que leyeras esto:
http://www.thewindowsclub.com/windows-10-activation-errors
Además, este es un foro de habla inglesa, use Google Translate para convertir de español a inglés en el futuro.
I would recommend you read through this:
http://www.thewindowsclub.com/windows-10-activation-errors
Also, this is an english-speaking forums, please use Google Translate to convert from spanish to english in the future.
@ITSolutions said:
But if you are only worried about keeping the images and no database I would go a slightly different route. It will take a little more time but get all your images converted tot he new partclone from partimage that previous versions used. The first thing is find a spare machine that has a big enough drive to hold your largest image(doesn’t matter if it is the same model or brand). Then pull each image down from the old FOG server, DO NOT let the machine reboot to the image and then create the image definition on your new machine and push it up tot he new machine. You will have to do that with each image.
In this situation, I’d say this is the more superior option.
I only did it the way I did because I was going from the latest FOG Trunk server - to another latest FOG Trunk server - my images were already in the latest and greatest image format. I was migrating a physical machine to an identical virtual environment and I didn’t want to use some shabby clunky physical2virtual process.
@Quazz I think when there is not a shebang, the linux terminal interprets it as a bash script. I looked back in the commit history, there has never been a shebang in that script… it’s worked several times. At any rate, I’m going to add it.
@Arrowhead-IT said:
Something to understand about multicast (and someone should correct me if I’m wrong) is that is does all the decompression on the server and then sends the packets out following multicast protocol.
That’s wrong, multicast sends the data compressed just like unicast deployments do. Decompression happens on the client side. And the idea of multicast is to broadcast throughout a broadcast domain, in order to send data only once instead of many times. There is a lot of overhead with multicast, but the more clients that are receiving the stream, the bigger the payoff.
Don’t feel bad - I thought the same thing, but tom corrected me then as I am now for you. The post is somewhere on here - from maybe a year ago lol.
@ch3i said in BASH on Windows 10 … and maybe FOG also?:
@Wayne-Workman Hi Wayne, FOG 2.0 will come with cross platform support, no ?
From what I understand, yes. But we might not have to wait for 2.0… I personally don’t have an interest in running FOG on Windows - but I want to know if it’s possible or not, at this point it’s just a curiosity.
@JJ-Fullmer I commented on your PR, I’m concerned about the licensing.
@moses said:
Quick question regarding this setup on trunk: for the DCHP servers that are each site, should they point to the Master FOG server at the HQ location, or should they point to the storage node that is onsite? Keep in mind the goal is to have clients download images from whichever server is at the site they happen to be at.
Either will work with newer systems and most older ones, but based on my recent experience with this, I would recommend you setup each site’s DHCP to point to that site’s storage node.
@NCMikeD said:
I don’t use sysprep on any of the other images I deal with, and I would prefer not to use it on this image as well. The only lingering doubt in my mind is my current version of fogprep. Is there a specific version of Fogprep for Win 7 64?
You don’t have to use FOGPrep. I don’t. It’s not necessary at all.
In fact, I believe it’s somehow become obsolete/legacy. I don’t remember the specifics.
You may be able to do what you want using snapins and a 3rd party tool.
There’s also a bit of work I’ve put together to allow fog to use any IP at any location and just work. https://github.com/wayneworkman/FOGUpdateIP
Would you be willing to upgrade to 1.2.0 and see if that works?
@chimchild Man, honestly, tell your uni to go to wal-mart and get a 30 dollar router. (or something better).
I just threw together this example using an MSI, in this case Google Chrome.
https://wiki.fogproject.org/wiki/index.php?title=FOG_Snapin_Examples
Hopefully this will get you started.
I’ll do Java tomorrow if I have time, and maybe a few for batch files and powershell files.
@need2 said:
I’m fairly certain there was a bug with 8/8.1 in FOG 1.2.0. It is working fine in the latest SVN, but I suggest caution if you use FOG in production, since the SVN is the development branch. Bugs happen.
For using the latest FOG Trunk versions,
It’d say it’s paramount to have FOG virtualized and maintain snapshots.
Hyper-V makes upgrading to trunk really easy… Don’t like the new version? Apply the last snapshot. Done.