{"id":225,"date":"2009-02-02T12:05:03","date_gmt":"2009-02-02T02:35:03","guid":{"rendered":"http:\/\/www.clearchain.com\/blog\/?p=225"},"modified":"2009-02-02T12:16:18","modified_gmt":"2009-02-02T02:46:18","slug":"samba-ads-nightmares","status":"publish","type":"post","link":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares","title":{"rendered":"samba ADS nightmares"},"content":{"rendered":"<p>Recently Ben and I have been trying to get a FreeBSD box to join an Active Directory domain. The domain controller was running Windows Server 2008. After a *lot* of stuffing around to get this working we finally found the solution to our problem &#8211; the version of samba.<br \/>\nYou see the problem we were facing was:<\/p>\n<pre># net ads join -U cis-closebs\r\ncis-closebs's password:\r\nFailed to join domain: Improperly formed account name<\/pre>\n<p>Now we checked the logs, checked kerberos, samba, but could not get this working. The debug logs showed something but nothing really useful:<\/p>\n<pre># net ads join -U cis-closebs\r\ncis-closebs's password:\r\nFailed to join domain: Improperly formed account name\r\n# net ads join -d 3 -U cis-closebs\r\n[2009\/02\/02 12:55:26, 3] param\/loadparm.c:lp_load(5031)\r\n  lp_load: refreshing parameters\r\n[2009\/02\/02 12:55:26, 3] param\/loadparm.c:init_globals(1430)\r\n  Initialising global parameters\r\n[2009\/02\/02 12:55:26, 3] param\/params.c:pm_process(572)\r\n  params.c:pm_process() - Processing configuration file \"\/usr\/local\/etc\/smb.conf\"\r\n[2009\/02\/02 12:55:26, 3] param\/loadparm.c:do_section(3770)\r\n  Processing section \"[global]\"\r\n[2009\/02\/02 12:55:26, 2] lib\/interface.c:add_interface(81)\r\n  added interface ip=130.220.236.62 bcast=130.220.237.255 nmask=255.255.254.0\r\n[2009\/02\/02 12:55:26, 3] libsmb\/namequery.c:get_dc_list(1489)\r\n  get_dc_list: preferred server list: \"130.220.64.77, uninet.unisa.edu.au, *\"\r\n[2009\/02\/02 12:55:26, 3] libads\/ldap.c:ads_connect(394)\r\n  Connected to LDAP server 130.220.64.77\r\n[2009\/02\/02 12:55:26, 3] libsmb\/namequery.c:get_dc_list(1489)\r\n  get_dc_list: preferred server list: \"130.220.64.77, uninet.unisa.edu.au, *\"\r\n[2009\/02\/02 12:55:26, 3] libsmb\/namequery.c:get_dc_list(1489)\r\n  get_dc_list: preferred server list: \"130.220.64.77, uninet.unisa.edu.au, *\"\r\ncis-closebs's password:\r\n[2009\/02\/02 12:55:27, 3] libsmb\/namequery.c:get_dc_list(1489)\r\n  get_dc_list: preferred server list: \"130.220.64.77, uninet.unisa.edu.au, *\"\r\n[2009\/02\/02 12:55:27, 3] libads\/ldap.c:ads_connect(394)\r\n  Connected to LDAP server 130.220.64.77\r\n[2009\/02\/02 12:55:27, 3] libads\/sasl.c:ads_sasl_spnego_bind(213)\r\n  ads_sasl_spnego_bind: got OID=1 2 840 48018 1 2 2\r\n[2009\/02\/02 12:55:27, 3] libads\/sasl.c:ads_sasl_spnego_bind(213)\r\n  ads_sasl_spnego_bind: got OID=1 2 840 113554 1 2 2\r\n[2009\/02\/02 12:55:27, 3] libads\/sasl.c:ads_sasl_spnego_bind(213)\r\n  ads_sasl_spnego_bind: got OID=1 2 840 113554 1 2 2 3\r\n[2009\/02\/02 12:55:27, 3] libads\/sasl.c:ads_sasl_spnego_bind(213)\r\n  ads_sasl_spnego_bind: got OID=1 3 6 1 4 1 311 2 2 10\r\n[2009\/02\/02 12:55:27, 3] libads\/sasl.c:ads_sasl_spnego_bind(222)\r\n  ads_sasl_spnego_bind: got server principal name = not_defined_in_RFC4178@please_ignore\r\n[2009\/02\/02 12:55:27, 3] libsmb\/clikrb5.c:ads_krb5_mk_req(593)\r\n  ads_krb5_mk_req: krb5_cc_get_principal failed (No such file or directory)\r\n[2009\/02\/02 12:55:27, 1] libsmb\/clikrb5.c:ads_krb5_mk_req(602)\r\n  ads_krb5_mk_req: krb5_get_credentials failed for not_defined_in_RFC4178@please_ignore (Server not found in Kerberos database)\r\n[2009\/02\/02 12:55:27, 1] utils\/net_ads.c:net_ads_join(1470)\r\n  error on ads_startup: Server not found in Kerberos database\r\nFailed to join domain: Improperly formed account name\r\n[2009\/02\/02 12:55:27, 2] utils\/net.c:main(1036)\r\n  return code = -1<\/pre>\n<p>Turns out that it was the version of samba we were using. Version 3.0.28 had issues with joining a Windows Server 2008 Active Directory domain. This was fixed in Samba 3.0.28a and as can be seen with the <a href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile\">FreeBSD ports commit<\/a>:<\/p>\n<table border=\"1\">\n<tbody>\n<tr>\n<td>\n<p style=\"padding-left: 60px; \">Revision\u00a0<strong>1.169<\/strong>:\u00a0<a class=\"download-link\" href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/~checkout~\/ports\/net\/samba3\/Makefile?rev=1.169;content-type=text%2Fplain\">download<\/a>\u00a0&#8211; view:\u00a0<a class=\"display-link\" href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile?rev=1.169;content-type=text%2Fplain\">text<\/a>,\u00a0<a class=\"display-link\" href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile?rev=1.169;content-type=text%2Fx-cvsweb-markup\">markup<\/a>,\u00a0<a href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile?annotate=1.169\">annotated<\/a>\u00a0&#8211;\u00a0<a href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile?r1=1.169#rev1.169\">select\u00a0for\u00a0diffs<\/a><br \/>\n<em>Thu May 1 16:32:53 2008 UTC<\/em>\u00a0(9 months ago) by\u00a0<em>timur<\/em><br \/>\nBranches:\u00a0<a href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile?only_with_tag=MAIN\">MAIN<\/a><br \/>\nDiff to: previous 1.168:\u00a0<a href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile.diff?r1=1.168;r2=1.169\">preferred<\/a>,\u00a0<a href=\"http:\/\/www.freebsd.org\/cgi\/cvsweb.cgi\/ports\/net\/samba3\/Makefile.diff?r1=1.168;r2=1.169;f=h\">colored<\/a><br \/>\nChanges since revision 1.168: +2 -2 lines<\/p>\n<pre class=\"log\">Update port to the 3.0.28a revision.\r\n\r\nMajor changes:\r\n\r\n  o Failure to join Windows 2008 domains\r\n  o Windows Vista (including SP1 RC) interop issues\r\n\r\nApproved by:\tshaun (mentor, implicit)<\/pre>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>So if you find yourself hunting around chasing something that surely should work.. consider upgrading samba!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Recently Ben and I have been trying to get a FreeBSD box to join an Active Directory domain. The domain controller was running Windows Server 2008. After a *lot* of stuffing around to get this working we finally found the solution to our problem &#8211; the version of samba. You see the problem we were<a href=\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares\"> <font size=-2>[..more..]<\/font><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[21,6],"tags":[132,131,134,133,130],"class_list":["post-225","post","type-post","status-publish","format-standard","hentry","category-opensource","category-unisa","tag-active-directory","tag-ad","tag-domain","tag-net-ads","tag-samba"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>samba ADS nightmares - ClearChain<\/title>\n<meta name=\"description\" content=\"Recently Ben and I have been trying to get a FreeBSD box to join an Active Directory domain. The domain controller was running Windows Server 2008. After\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Benjamin Close\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares\"},\"author\":{\"name\":\"Benjamin Close\",\"@id\":\"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/aef6faa2c32188398139db9270ca1c98\"},\"headline\":\"samba ADS nightmares\",\"datePublished\":\"2009-02-02T02:35:03+00:00\",\"dateModified\":\"2009-02-02T02:46:18+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares\"},\"wordCount\":167,\"commentCount\":0,\"keywords\":[\"active directory\",\"ad\",\"domain\",\"net ads\",\"samba\"],\"articleSection\":[\"OpenSource\",\"UniSA\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares\",\"url\":\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares\",\"name\":\"samba ADS nightmares - ClearChain\",\"isPartOf\":{\"@id\":\"https:\/\/www.clearchain.com\/blog\/#website\"},\"datePublished\":\"2009-02-02T02:35:03+00:00\",\"dateModified\":\"2009-02-02T02:46:18+00:00\",\"author\":{\"@id\":\"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/aef6faa2c32188398139db9270ca1c98\"},\"description\":\"Recently Ben and I have been trying to get a FreeBSD box to join an Active Directory domain. The domain controller was running Windows Server 2008. After\",\"breadcrumb\":{\"@id\":\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.clearchain.com\/blog\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"samba ADS nightmares\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.clearchain.com\/blog\/#website\",\"url\":\"https:\/\/www.clearchain.com\/blog\/\",\"name\":\"ClearChain\",\"description\":\"-= Daily Happenings =-\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.clearchain.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/aef6faa2c32188398139db9270ca1c98\",\"name\":\"Benjamin Close\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/19dca0aa372edfa901b93c556dfda2e78ad4434558fe4d139598e086315d714a?s=96&d=mm&r=pg\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/19dca0aa372edfa901b93c556dfda2e78ad4434558fe4d139598e086315d714a?s=96&d=mm&r=pg\",\"caption\":\"Benjamin Close\"},\"sameAs\":[\"http:\/\/www.clearchain.com\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"samba ADS nightmares - ClearChain","description":"Recently Ben and I have been trying to get a FreeBSD box to join an Active Directory domain. The domain controller was running Windows Server 2008. After","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares","twitter_misc":{"Written by":"Benjamin Close","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#article","isPartOf":{"@id":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares"},"author":{"name":"Benjamin Close","@id":"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/aef6faa2c32188398139db9270ca1c98"},"headline":"samba ADS nightmares","datePublished":"2009-02-02T02:35:03+00:00","dateModified":"2009-02-02T02:46:18+00:00","mainEntityOfPage":{"@id":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares"},"wordCount":167,"commentCount":0,"keywords":["active directory","ad","domain","net ads","samba"],"articleSection":["OpenSource","UniSA"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares","url":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares","name":"samba ADS nightmares - ClearChain","isPartOf":{"@id":"https:\/\/www.clearchain.com\/blog\/#website"},"datePublished":"2009-02-02T02:35:03+00:00","dateModified":"2009-02-02T02:46:18+00:00","author":{"@id":"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/aef6faa2c32188398139db9270ca1c98"},"description":"Recently Ben and I have been trying to get a FreeBSD box to join an Active Directory domain. The domain controller was running Windows Server 2008. After","breadcrumb":{"@id":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.clearchain.com\/blog\/posts\/samba-ads-nightmares#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.clearchain.com\/blog"},{"@type":"ListItem","position":2,"name":"samba ADS nightmares"}]},{"@type":"WebSite","@id":"https:\/\/www.clearchain.com\/blog\/#website","url":"https:\/\/www.clearchain.com\/blog\/","name":"ClearChain","description":"-= Daily Happenings =-","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.clearchain.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/aef6faa2c32188398139db9270ca1c98","name":"Benjamin Close","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.clearchain.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/19dca0aa372edfa901b93c556dfda2e78ad4434558fe4d139598e086315d714a?s=96&d=mm&r=pg","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/19dca0aa372edfa901b93c556dfda2e78ad4434558fe4d139598e086315d714a?s=96&d=mm&r=pg","caption":"Benjamin Close"},"sameAs":["http:\/\/www.clearchain.com"]}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/posts\/225","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/comments?post=225"}],"version-history":[{"count":7,"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/posts\/225\/revisions"}],"predecessor-version":[{"id":232,"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/posts\/225\/revisions\/232"}],"wp:attachment":[{"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/media?parent=225"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/categories?post=225"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.clearchain.com\/blog\/wp-json\/wp\/v2\/tags?post=225"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}