Community Forum

anwoke8204
anwoke8204
Offline
Resolved
0 votes
hi, I noticed that I for some reason had the clearos-testing repo enabled, and it updated openldap as well as the accounts app and now I get the account system is offline, I try to restart the service and it restarts fine, and shows its running, but according to the web gui, its offline, how can I fix this?
Saturday, March 09 2013, 06:58 PM
Share this post:
Responses (16)
  • Accepted Answer

    Tuesday, December 05 2017, 09:30 PM - #Permalink
    Resolved
    0 votes
    Odd. That says LDAP is already running. It is listening for ldap and ldaps on localhost and ldaps on your LAN interface.

    Have I misunderstood something as I am not familiar with the AD connector set up? Is it worth rebooting the server at this point? Alternatively you can try a "service slapd stop" and see if 'netstat -peanut | grep LIST | egrep "389|636"' then shows nothing, then restart it. Or do a "ps aux | grep slapd" and kill any process, before restarting slapd. I'd prefer the reboot.
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 08:26 PM - #Permalink
    Resolved
    0 votes
    Here is the results I think my LDAP I mean Domain Controller IP is 192.168.2.8.
    fist ip (192.168.2.1 is wrong i think?

    [root@gateway ~]# netstat -peanut | grep LIST | egrep "389|636"
    tcp 0 0 192.168.2.1:636 0.0.0.0:* LISTEN 0 15183568 17742/slapd
    tcp 0 0 127.0.0.1:636 0.0.0.0:* LISTEN 0 15183567 17742/slapd
    tcp 0 0 127.0.0.1:389 0.0.0.0:* LISTEN 0 15183566 17742/slapd
    [root@gateway ~]#
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, December 05 2017, 08:21 PM - #Permalink
    Resolved
    0 votes
    What is the output of:
    netstat -peanut | grep LIST | egrep "389|636"
    It is strange when it says the address is already in use.
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 08:00 PM - #Permalink
    Resolved
    0 votes
    Another error is

    .bash_logoutâ: No such file or directory
    Dec 5 23:00:02 gateway engine: exception: debug backtrace: /usr/clearos/apps/base/libraries/File.php (1203): execute
    Dec 5 23:00:02 gateway engine: exception: debug backtrace: /var/clearos/events/accounts/accounts (131): copy_to
    Dec 5 23:00:02 gateway engine: exception: error: /usr/clearos/apps/base/libraries/Shell.php (227): /bin/cp: cannot stat â/etc/skel/+0300 .bash_logoutâ: No such file or directory
    Dec 5 23:00:02 gateway engine: exception: debug backtrace: /usr/clearos/apps/base/libraries/File.php (1203): execute
    Dec 5 23:00:02 gateway engine: exception: debug backtrace: /var/clearos/events/accounts/accounts (131): copy_to
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 07:55 PM - #Permalink
    Resolved
    0 votes
    I think there is some kind of misconfigured settings or

     [root@gateway ~]# /usr/sbin/slapd -h 'ldap://127.0.0.1/ ldaps://127.0.0.1/' -u ldap -d -1
    ldap_url_parse_ext(ldap://localhost/)
    ldap_init: trying /etc/openldap/ldap.conf
    ldap_init: using /etc/openldap/ldap.conf
    ldap_init: HOME env is /root
    ldap_init: trying /root/ldaprc
    ldap_init: trying /root/.ldaprc
    ldap_init: LDAPCONF env is NULL
    ldap_init: LDAPRC env is NULL
    5a26f643 @(#) $OpenLDAP: slapd 2.4.44 (Aug 12 2017 06:10:11) $
    mockbuild@build64-1.clearsdn.local:/builddir/build/BUILD/openldap-2.4.44/openldap-2.4.44/servers/slapd
    ldap_pvt_gethostbyname_a: host=gateway.aysis.org, r=0
    5a26f643 daemon_init: ldap://127.0.0.1/ ldaps://127.0.0.1/
    5a26f643 daemon_init: listen on ldap://127.0.0.1/
    5a26f643 daemon_init: listen on ldaps://127.0.0.1/
    5a26f643 daemon_init: 2 listeners to open...
    ldap_url_parse_ext(ldap://127.0.0.1/)
    5a26f643 daemon: bind(7) failed errno=98 (Address already in use)
    5a26f643 slap_open_listener: failed on ldap://127.0.0.1/
    5a26f643 slapd stopped.
    5a26f643 connections_destroy: nothing to destroy.
    [root@gateway ~]#
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 07:42 PM - #Permalink
    Resolved
    0 votes
    /usr/sbin/slapd -h 'ldap://127.0.0.1/ ldaps://127.0.0.1/' -u ldap -d -1

    Here is the output

    [root@gateway ~]# /usr/sbin/slapd -h 'ldap://127.0.0.1/ ldaps://127.0.0.1/' -u ldap -d -1
    ldap_url_parse_ext(ldap://localhost/)
    ldap_init: trying /etc/openldap/ldap.conf
    ldap_init: using /etc/openldap/ldap.conf
    ldap_init: HOME env is /root
    ldap_init: trying /root/ldaprc
    ldap_init: trying /root/.ldaprc
    ldap_init: LDAPCONF env is NULL
    ldap_init: LDAPRC env is NULL
    5a26f643 @(#) $OpenLDAP: slapd 2.4.44 (Aug 12 2017 06:10:11) $
    mockbuild@build64-1.clearsdn.local:/builddir/build/BUILD/openldap-2.4.44/openldap-2.4.44/servers/slapd
    ldap_pvt_gethostbyname_a: host=gateway.aysis.org, r=0
    5a26f643 daemon_init: ldap://127.0.0.1/ ldaps://127.0.0.1/
    5a26f643 daemon_init: listen on ldap://127.0.0.1/
    5a26f643 daemon_init: listen on ldaps://127.0.0.1/
    5a26f643 daemon_init: 2 listeners to open...
    ldap_url_parse_ext(ldap://127.0.0.1/)
    5a26f643 daemon: bind(7) failed errno=98 (Address already in use)
    5a26f643 slap_open_listener: failed on ldap://127.0.0.1/
    5a26f643 slapd stopped.
    5a26f643 connections_destroy: nothing to destroy.
    [root@gateway ~]#
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, December 05 2017, 07:35 PM - #Permalink
    Resolved
    0 votes
    Searching old posts, can you start ldap with:
    /usr/sbin/slapd -h 'ldap://127.0.0.1/ ldaps://127.0.0.1/' -u ldap -d -1
    Look for error messages and check your logs afterwards.

    Don't worry about /etc/openldap/slap.d not existing. It should not. If it did, it is an indication of another issue.
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 06:47 PM - #Permalink
    Resolved
    0 votes
    Hi,

    I tried with tail -f and then The only think i see is below :( I think I need to reconfigure or reinstall this even If I do not know It's possible but I do not know where to look anymore? :(
    is it possible to put back /etc/openldap/slap.d from somwhere?

    Dec 5 21:43:27 prestart.sh: Configuration directory '/etc/openldap/slapd.d' does not exist.
    Dec 5 21:43:27 prestart.sh: Warning: Usage of a configuration file is obsolete!
    Dec 5 21:43:27 systemd: slapd.service: control process exited, code=exited status=1
    Dec 5 21:43:27 systemd: Failed to start OpenLDAP Server Daemon.
    Dec 5 21:43:27 systemd: Unit slapd.service entered failed state.
    Dec 5 21:43:27 systemd: slapd.service failed.
    Dec 5 21:44:10 systemd: Starting OpenLDAP Server Daemon...
    Dec 5 21:44:10 prestart.sh: Configuration directory '/etc/openldap/slapd.d' does not exist.
    Dec 5 21:44:10 prestart.sh: Warning: Usage of a configuration file is obsolete!
    Dec 5 21:44:10 systemd: slapd.service: control process exited, code=exited status=1
    Dec 5 21:44:10 systemd: Failed to start OpenLDAP Server Daemon.
    Dec 5 21:44:10 systemd: Unit slapd.service entered failed state.
    Dec 5 21:44:10 systemd: slapd.service failed.
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, December 05 2017, 06:04 PM - #Permalink
    Resolved
    0 votes
    Your configuration looks OK.

    The Directory Server app is Webconfig > Server > Directory > Directory Server but I don't think there will be any issue there.

    When it fails to start, is there anything in /var/log/messages or /var/log/system which gives any indication of an issue.
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 04:41 PM - #Permalink
    Resolved
    0 votes
    Thanks for the reply Nich,

    Please find my ifconfig result. I am not sure how to find misconfigured WAN connection in ClearOS . For example you means that ens35 WAN connection IP address should be the same n my LAN IP block? like 192.168.2.5 but subnet should be 255.255.254.0?

    Also How can i find my Publish Policy in Directory Server App? which menu I have to follow?

    [root@gateway ~]# ifconfig
    ens32: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
    inet 192.168.2.1 netmask 255.255.255.0 broadcast 192.168.2.255
    inet6 fe80::20c:29ff:fe02:585c prefixlen 64 scopeid 0x20<link>
    ether 00:0c:29:02:58:5c txqueuelen 1000 (Ethernet)
    RX packets 21870842 bytes 8432302961 (7.8 GiB)
    RX errors 0 dropped 9 overruns 0 frame 0
    TX packets 25132154 bytes 21420665871 (19.9 GiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    ens33: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
    inet 192.168.1.254 netmask 255.255.255.0 broadcast 192.168.1.255
    inet6 fe80::20c:29ff:fe02:5870 prefixlen 64 scopeid 0x20<link>
    ether 00:0c:29:02:58:70 txqueuelen 1000 (Ethernet)
    RX packets 10489428 bytes 6388921334 (5.9 GiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 10551340 bytes 7683728152 (7.1 GiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    ens35: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
    inet 192.168.3.254 netmask 255.255.255.0 broadcast 192.168.3.255
    inet6 fe80::20c:29ff:fe02:5866 prefixlen 64 scopeid 0x20<link>
    ether 00:0c:29:02:58:66 txqueuelen 1000 (Ethernet)
    RX packets 13366105 bytes 13756858500 (12.8 GiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 8223182 bytes 1747933301 (1.6 GiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
    inet 127.0.0.1 netmask 255.0.0.0
    inet6 ::1 prefixlen 128 scopeid 0x10<host>
    loop txqueuelen 1 (Local Loopback)
    RX packets 196328 bytes 291148282 (277.6 MiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 196328 bytes 291148282 (277.6 MiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    tun0: flags=4305<UP,POINTOPOINT,RUNNING,NOARP,MULTICAST> mtu 1500
    inet 10.8.0.1 netmask 255.255.255.255 destination 10.8.0.2
    inet6 fe80::24b:248e:7b06:7a07 prefixlen 64 scopeid 0x20<link>
    unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 100 (UNSPEC)
    RX packets 308179 bytes 34809370 (33.1 MiB)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 380544 bytes 227120445 (216.5 MiB)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

    tun1: flags=4305<UP,POINTOPOINT,RUNNING,NOARP,MULTICAST> mtu 1500
    inet 10.8.10.1 netmask 255.255.255.255 destination 10.8.10.2
    inet6 fe80::cacc:6c4a:ea19:faab prefixlen 64 scopeid 0x20<link>
    unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 100 (UNSPEC)
    RX packets 0 bytes 0 (0.0 B)
    RX errors 0 dropped 0 overruns 0 frame 0
    TX packets 3 bytes 144 (144.0 B)
    TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, December 05 2017, 02:49 PM - #Permalink
    Resolved
    0 votes
    Guessing here. Is one of your WAN interfaces unconfigured? If so, please try changing it to LAN and give it a fixed IP on a different subnet from ens32.

    [edit]
    In your Directory Server app, what is your Publsh Policy?
    [/edit]
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 01:09 PM - #Permalink
    Resolved
    0 votes
    Hi;

    All outputs of you asked me is here. I am not expert of ClearOS or linux. So I really do not know where to start. If you can see any clue maybe you can say that where to start.
    Thanks for the help Nick.

    [root@gateway ~]# ls /sys/class/net
    ens32 ens33 ens35 lo tun0 tun1

    [root@gateway ~]# cat /etc/clearos/network.conf
    # Network mode
    MODE="gateway"

    # Network interface roles
    EXTIF="ens33 ens35"
    LANIF="ens32"
    DMZIF=""
    HOTIF=""

    # Domain and Internet Hostname
    DEFAULT_DOMAIN="aysis.org"
    INTERNET_HOSTNAME="gateway.aysis.org"

    # Extra LANS
    EXTRALANS=""

    # ISP Maximum Speeds
    ENS35_MAX_DOWNSTREAM=0
    ENS35_MAX_UPSTREAM=0
    ENS32_MAX_DOWNSTREAM=0
    ENS32_MAX_UPSTREAM=0
    ENS160_MAX_DOWNSTREAM=0
    ENS160_MAX_UPSTREAM=0
    ENS33_MAX_DOWNSTREAM=0
    ENS33_MAX_UPSTREAM=0
    [root@gateway ~]#



    [root@gateway ~]# service slapd start
    Redirecting to /bin/systemctl start slapd.service
    Job for slapd.service failed because the control process exited with error code. See "systemctl status slapd.service" and "journalctl -xe" for details.
    [root@gateway ~]# systemctl status slapd.service
    â slapd.service - OpenLDAP Server Daemon
    Loaded: loaded (/usr/lib/systemd/system/slapd.service; enabled; vendor preset: disabled)
    Active: failed (Result: exit-code) since Tue 2017-12-05 16:06:06 +03; 15s ago
    Docs: man:slapd
    man:slapd-config
    man:slapd-hdb
    man:slapd-mdb
    file:///usr/share/doc/openldap-servers/guide.html
    Process: 23627 ExecStart=/usr/sbin/slapd -u ldap -h ${SLAPD_URLS} $SLAPD_OPTIONS (code=exited, status=1/FAILURE)
    Process: 23612 ExecStartPre=/usr/libexec/openldap/prestart.sh (code=exited, status=0/SUCCESS)
    Main PID: 13430 (code=exited, status=0/SUCCESS)

    systemd[1]: Starting OpenLDAP Server Daemon...
    prestart.sh[23612]: Configuration directory '/etc/openldap/slapd.d' does not exist.
    prestart.sh[23612]: Warning: Usage of a configuration file is obsolete!
    runuser[23616]: pam_unix(runuser:session): session opened for user ldap by (uid=0)
    slapd[23627]: @(#) $OpenLDAP: slapd 2.4.44 (Aug 12 2017 06:10:11) $ mockbuild@build64-1.clearsdn.local:/builddir/build/BUILD/openldap-2.4.44/openldap-2.4.44/servers/slapd
    systemd[1]: slapd.service: control process exited, code=exited status=1
    systemd[1]: Failed to start OpenLDAP Server Daemon.
    systemd[1]: Unit slapd.service entered failed state.
    systemd[1]: slapd.service failed.
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, December 05 2017, 12:21 PM - #Permalink
    Resolved
    0 votes
    Unfortunately if you do not have the folder /etc/openldap/slapd.d then it is not the same issue as I linked to and you don't qualify for the free support offer.

    If you start LDAP manually ("service slapd start"), do you see any errors? Also is there anything in the logs?

    What is the contents of /etc/clearos/network.conf and the output of "ls /sys/class/net"?
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Tuesday, December 05 2017, 11:57 AM - #Permalink
    Resolved
    0 votes
    Hi;

    automatically update is enabled and I do not have a folder /etc/openldap/slapd.d. I did not understand that how to raise it as a General Enquiry? You mean can iopen a free tickedt in Generel category?

    Thanks in advance...
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, December 05 2017, 11:40 AM - #Permalink
    Resolved
    0 votes
    Hello Cumhur,
    Can you look back in your yum log and see if the issue was related to the 7.4 update? The update would have happened automatically on or around 20th Oct, but if you are updating manually, could have happened later. Do you have a folder /etc/openldap/slapd.d? If so, you have hit a rare bug and the fix is here. If you do believe this is the issue and don't feel confident of following the instructions, you are welcome to raise a support ticket for free (raise it as a General Enquiry).
    The reply is currently minimized Show
  • Accepted Answer

    Cumhur ata
    Cumhur ata
    Offline
    Monday, December 04 2017, 09:15 PM - #Permalink
    Resolved
    0 votes
    Hi,

    I have the same problem. Everything was working great but since last 2 weeks I have been receiving this error When i click some menus like Network Map, Accounts/users ...
    MS AD connects successfully but i think I cannot get a some kind of connection or something blocks. I did a little bit research that i could find this error below. I am not sure it's related to or not. is there anyone to give me a clue to fix this?

    Starting OpenLDAP Server Daemon...
    : Configuration directory '/etc/openldap/slapd.d' does not exist.
    prestart.sh[17871]: Warning: Usage of a configuration file is obsolete!
    runuser[17875]: pam_unix(runuser:session): session opened for user ldap by (uid=0)
    slapd[17886]: @(#) $OpenLDAP: slapd 2.4.44 (Aug 12 2017 06:10:11) $ mockbuild@build64-1.clearsdn.local:/builddir/build/BUILD/openldap-2.4.44/openldap-2.4.44/servers/slapd
    systemd[1]: slapd.service: control process exited, code=exited status=1
    systemd[1]: Failed to start OpenLDAP Server Daemon.
    systemd[1]: Unit slapd.service entered failed state.
    systemd[1]: slapd.service failed.


    Thanks in advance.
    Cumhur Ata
    The reply is currently minimized Show
Your Reply