• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    FOG running under Linux Bash Shell on Windows 10

    Scheduled Pinned Locked Moved
    General
    3
    8
    4.1k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • x23piracyX
      x23piracy
      last edited by x23piracy

      Hi,

      today i tried to install FOG on the Linux Bash Microsoft has introduced with Windows 10:
      https://msdn.microsoft.com/de-de/commandline/wsl/install_guide

      They updated from Ubuntu 14 to 16, i just activated it and tried to install FOG and it works:

      alt text

      alt text

      The Linux Filesystem is located here:

      alt text

      Just wanted to let you know its working, maybe its interesting for someone.

      The main problem is when you close the command prompt (leave bash) it will close down anything, that means if you start the bash again nothing is running, no apach, no mysql, no fog services.

      I think i need to create a start script that’s triggering the bash itself and runs some commands in it:

      set ws=wscript.createobject("wscript.shell")
      ws.run "C:\Windows\System32\bash.exe -c 'sudo DOSTUFF'",0
      

      What is needed to start? Can someone help me collecting everything needed?

      • Apache
      • MySQL
      • NFS
      • RPC
      • DHCP (if needed)
      • TFTP
      • PXE
      • VSFTP
      • FOG Multicastmanager, Image Replicator, Snapin Replicator, Scheduler, PingHosts, SnapinHash and ImageSize

      Anything else? Howto start the FOG Services manually?
      Is there a command to start everything needed instead of executing foginstall script again?

      Regards X23

      ║▌║█║▌│║▌║▌█

      1 Reply Last reply Reply Quote 0
      • Wayne WorkmanW
        Wayne Workman
        last edited by Wayne Workman

        You are ahead of us. The list there looks good enough to start with. FOG was designed to run on Linux - so you’ll just need to write your own scripts for starting everything up. The commands on Ubuntu 16.04 to start/stop services are just systemctl start blah Also, pretty cool that you got this going! I’ll stick with my Linux though 🙂

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!
        Daily Clean Installation Results:
        https://fogtesting.fogproject.us/
        FOG Reporting:
        https://fog-external-reporting-results.fogproject.us/

        x23piracyX 1 Reply Last reply Reply Quote 0
        • x23piracyX
          x23piracy @Wayne Workman
          last edited by x23piracy

          @Wayne-Workman well wayne i don’t want to use this productive, just a try to waste a bunch of time 😄

          root@x23i7:/home# ./startFOG.sh
           * Starting Apache httpd web server apache2                                                                             [Mon Apr 17 15:23:48.994516 2017] [core:warn] [pid 43] (92)Protocol not available: AH00076: Failed to enable APR_TCP_DEFER_ACCEPT
          [Mon Apr 17 15:23:48.994953 2017] [core:warn] [pid 43] (92)Protocol not available: AH00076: Failed to enable APR_TCP_DEFER_ACCEPT
           *
           * Starting MySQL database server mysqld                                                                                No directory, logging in with HOME=/
                                                                                                                           [ OK ]
           * Starting FTP server vsftpd                                                                                    [ OK ]
           * Starting HPA's tftpd in.tftpd                                                                                 [ OK ]
           * Starting internet superserver xinetd                                                                          [ OK ]
           * Starting FOG Computer Imaging Solution: FOGMulticastManager                                                   [ OK ]
           * Starting FOG Computer Imaging Solution: FOGImageReplicator                                                    [ OK ]
           * Starting FOG Computer Imaging Solution: FOGSnapinReplicator                                                   [ OK ]
          FOGTaskScheduler: unrecognized service
           * Starting FOG Computer Imaging Solution: FOGPingHosts                                                          [ OK ]
           * Starting FOG Computer Imaging Solution: FOGSnapinHash                                                         [ OK ]
           * Starting FOG Computer Imaging Solution: FOGImageSize                                                          [ OK ]
          root@x23i7:/home# service FOGTaskScheduler start
          FOGTaskScheduler: unrecognized service
          root@x23i7:/home#
          

          What the hell taskscheduler is not a serivce?
          Howto start the tftp like it started after foginstall.sh was running?

          it’s not service xinetd start, maybe service tftpd-hpa start?

          ║▌║█║▌│║▌║▌█

          1 Reply Last reply Reply Quote 0
          • x23piracyX
            x23piracy
            last edited by x23piracy

            Hi,

            that’s what i got so far:

            service apache2 start
            service php7.1-fpm start
            service mysql start
            service vsftpd start
            service tftpd-hpa start
            service FOGMulticastManager start
            service FOGImageReplicator start
            service FOGSnapinReplicator start
            service FOGPingHosts start
            service FOGSnapinHash start
            service FOGImageSize start
            /usr/bin/php -q /opt/fog/service/FOGTaskScheduler/FOGTaskScheduler &
            

            Why is the FOGTaskScheduler no registered Service?

            Is there a way to start all the services marked as startup service?

            service --status-all
            

            Using this command i can see the services are enabled to start but simply opening bash will bring my into an already booted system where just all the startup services has been forced to close. Is there a way to retrigger the service init?

            root@x23i7:/mnt/c/Users/x23# service --status-all
             [ + ]  FOGImageReplicator
             [ + ]  FOGImageSize
             [ + ]  FOGMulticastManager
             [ + ]  FOGPingHosts
             [ + ]  FOGScheduler
             [ + ]  FOGSnapinHash
             [ + ]  FOGSnapinReplicator
             [ - ]  acpid
             [ + ]  apache-htcacheclean
             [ + ]  apache2
             [ - ]  apparmor
             [ ? ]  apport
             [ - ]  atd
             [ - ]  bootmisc.sh
             [ - ]  checkfs.sh
             [ - ]  checkroot-bootclean.sh
             [ - ]  checkroot.sh
             [ - ]  console-setup
             [ - ]  cron
             [ ? ]  cryptdisks
             [ ? ]  cryptdisks-early
             [ - ]  dbus
             [ - ]  hostname.sh
             [ ? ]  hwclock.sh
             [ + ]  irqbalance
             [ + ]  iscsid
             [ - ]  keyboard-setup.dpkg-bak
             [ - ]  killprocs
             [ - ]  kmod
             [ - ]  lvm2
             [ + ]  lvm2-lvmetad
             [ + ]  lvm2-lvmpolld
             [ - ]  lxcfs
             [ - ]  lxd
             [ - ]  mdadm
             [ - ]  mdadm-waitidle
             [ - ]  mountall-bootclean.sh
             [ - ]  mountall.sh
             [ - ]  mountdevsubfs.sh
             [ - ]  mountkernfs.sh
             [ - ]  mountnfs-bootclean.sh
             [ - ]  mountnfs.sh
             [ + ]  mysql
             [ ? ]  networking
             [ - ]  nfs-kernel-server
             [ ? ]  ondemand
             [ + ]  open-iscsi
             [ - ]  open-vm-tools
             [ + ]  php7.1-fpm
             [ ? ]  plymouth
             [ ? ]  plymouth-log
             [ - ]  procps
             [ - ]  rc.local
             [ + ]  resolvconf
             [ - ]  rpcbind
             [ - ]  rsync
             [ - ]  rsyslog
             [ - ]  screen-cleanup
             [ - ]  sendsigs
             [ - ]  ssh
             [ + ]  tftpd-hpa
             [ - ]  udev
             [ - ]  ufw
             [ - ]  umountfs
             [ - ]  umountnfs.sh
             [ - ]  umountroot
             [ - ]  unattended-upgrades
             [ - ]  urandom
             [ - ]  uuidd
             [ + ]  vsftpd
             [ - ]  xinetd
            

            As you can see FOGTaskScheduler is no registered Service.

            Is the PXE Services started with TFTP?
            What about RPC Bind and NFS Server, howto start em?

            Regards X23

            ║▌║█║▌│║▌║▌█

            Tom ElliottT 1 Reply Last reply Reply Quote 1
            • Tom ElliottT
              Tom Elliott @x23piracy
              last edited by

              @x23piracy That’s because it’s FOGScheduler. Not FOGTaskScheduler.

              Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

              Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

              Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

              1 Reply Last reply Reply Quote 1
              • x23piracyX
                x23piracy
                last edited by x23piracy

                Hi,

                thats what i got so far within the linux subsystem i have this file (startFOG.sh😞

                service apache2 start
                service php7.1-fpm start
                service mysql start
                service vsftpd start
                service tftpd-hpa start
                service FOGMulticastManager start
                service FOGImageReplicator start
                service FOGSnapinReplicator start
                service FOGPingHosts start
                service FOGSnapinHash start
                service FOGImageSize start
                service FOGScheduler start
                read -rn1
                

                To run that as kind of service without having everything down when closing the bash window i use a vbs script:

                set ws=wscript.createobject("wscript.shell")
                ws.run "C:\Windows\System32\bash.exe -c '/home/startFOG.sh'",0
                

                This only works because my startFOG.sh has the “read -rn1” command as last line, this will wait for a key press like return or something and therefore helds the bash open until i close the process.

                Regards X23

                ║▌║█║▌│║▌║▌█

                Wayne WorkmanW 1 Reply Last reply Reply Quote 1
                • Wayne WorkmanW
                  Wayne Workman @x23piracy
                  last edited by

                  @x23piracy Does it deploy and capture as expected?

                  Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!
                  Daily Clean Installation Results:
                  https://fogtesting.fogproject.us/
                  FOG Reporting:
                  https://fog-external-reporting-results.fogproject.us/

                  x23piracyX 1 Reply Last reply Reply Quote 0
                  • x23piracyX
                    x23piracy @Wayne Workman
                    last edited by

                    @Wayne-Workman not tested yet, but i will try this but don’t expect it in the next hours 🙂

                    ║▌║█║▌│║▌║▌█

                    1 Reply Last reply Reply Quote 0
                    • 1 / 1
                    • First post
                      Last post

                    159

                    Online

                    12.0k

                    Users

                    17.3k

                    Topics

                    155.2k

                    Posts
                    Copyright © 2012-2024 FOG Project