{"id":9704,"date":"2018-06-22T15:39:29","date_gmt":"2018-06-22T13:39:29","guid":{"rendered":"http:\/\/www.b.shuttle.de\/hayek\/hayek\/jochen\/wp\/blog-en\/?p=9704"},"modified":"2018-06-22T15:39:29","modified_gmt":"2018-06-22T13:39:29","slug":"getent","status":"publish","type":"post","link":"https:\/\/wp.jochen.hayek.name\/blog-en\/2018\/06\/22\/getent\/","title":{"rendered":"getent &#8211; &#8220;get entries from administrative database&#8221;"},"content":{"rendered":"<ul>\n<li><a href=\"https:\/\/en.wikipedia.org\/wiki\/Getent\">https:\/\/en.wikipedia.org\/wiki\/Getent<\/a><\/li>\n<li><a href=\"https:\/\/manpages.debian.org\/unstable\/manpages\/getent.1.en.html\">https:\/\/manpages.debian.org\/unstable\/manpages\/getent.1.en.html<\/a><\/li>\n<\/ul>\n<blockquote><p>The\u00a0<b>getent<\/b>\u00a0command displays entries from databases supported by the Name Service Switch libraries, which are configured in\u00a0<i>\/etc\/nsswitch.conf<\/i>. If one or more\u00a0<i>key<\/i>\u00a0arguments are provided, then only the entries that match the supplied keys will be displayed. Otherwise, if no\u00a0<i>key<\/i>\u00a0is provided, all entries will be displayed (unless the database does not support enumeration).<\/p><\/blockquote>\n<p>My DS713+ (Intel based Synology NAS) does not have in on board, its Entware repository neither, but using &#8220;locate&#8221; I spotted a binary in a docker installation. It looks, like it is compiled for Debian, but it runs anyway.<\/p>\n<ul>\n<li><a href=\"https:\/\/cygwin.com\/packages\/x86_64\/getent\/\">https:\/\/cygwin.com\/packages\/x86_64\/getent\/<\/a>\u00a0&#8211; getent on cygwin<\/li>\n<\/ul>\n<p>getent on macOS: basically it&#8217;s not there and there is no way to get it, and it does not make sense to emulate it; use the right tools on macOS!<\/p>\n<ul>\n<li><a href=\"http:\/\/zzamboni.org\/brt\/2008\/01\/21\/how-to-emulate-unix-getent-with-macosxs-dscl\/\">http:\/\/zzamboni.org\/brt\/2008\/01\/21\/how-to-emulate-unix-getent-with-macosxs-dscl\/<\/a><\/li>\n<li><a href=\"https:\/\/apple.stackexchange.com\/questions\/44567\/how-can-i-install-getent-on-snow-leopard\">https:\/\/apple.stackexchange.com\/questions\/44567\/how-can-i-install-getent-on-snow-leopard<\/a><\/li>\n<li><a href=\"https:\/\/unix.stackexchange.com\/questions\/373309\/mac-os-command-to-resolve-hostnames-like-getent-on-linux\">https:\/\/unix.stackexchange.com\/questions\/373309\/mac-os-command-to-resolve-hostnames-like-getent-on-linux<\/a><\/li>\n<li><a href=\"https:\/\/superuser.com\/questions\/279891\/list-all-members-of-a-group-mac-os-x\/395738\">https:\/\/superuser.com\/questions\/279891\/list-all-members-of-a-group-mac-os-x\/395738<\/a><\/li>\n<li><a href=\"https:\/\/www.cyberciti.biz\/faq\/check-list-users-unix\/\">https:\/\/www.cyberciti.biz\/faq\/check-list-users-unix\/<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>https:\/\/en.wikipedia.org\/wiki\/Getent https:\/\/manpages.debian.org\/unstable\/manpages\/getent.1.en.html The\u00a0getent\u00a0command displays entries from databases supported by the Name Service Switch libraries, which are configured in\u00a0\/etc\/nsswitch.conf. If one or more\u00a0key\u00a0arguments are provided, then only the entries that match the supplied keys will be displayed. Otherwise, if no\u00a0key\u00a0is provided, all entries will be displayed (unless the database does not support enumeration). My DS713+ (Intel [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false,"_share_on_mastodon":"0"},"categories":[82,171,306,671,673],"tags":[],"class_list":["post-9704","post","type-post","status-publish","format-standard","hentry","category-cygwin","category-gnu","category-linux","category-unix","category-unix_utilities"],"share_on_mastodon":{"url":"","error":""},"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/saO0kP-getent","jetpack_likes_enabled":true,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/posts\/9704","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/comments?post=9704"}],"version-history":[{"count":0,"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/posts\/9704\/revisions"}],"wp:attachment":[{"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/media?parent=9704"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/categories?post=9704"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wp.jochen.hayek.name\/blog-en\/wp-json\/wp\/v2\/tags?post=9704"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}