Re: [OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-08-04 Thread sujith h
Hi,

I will post the new patch with ROOTFS_POSTPROCESS_COMMAND.

Thanks for the feedback.



On Fri, Aug 1, 2014 at 2:52 PM, Enrico Scholz 
enrico.sch...@sigma-chemnitz.de wrote:

 Otavio Salvador otavio-fkevb0iiklmbz+lybsd...@public.gmane.org writes:

  + echo 127.0.1.1  ${MACHINE} 
 ${D}${sysconfdir}/hosts
 
  This is a very questionable setup which causes a lot of harm.  When
  really wanted, it should be made optional and not the default.
 
  What kind of harm you see?

 e.g. in sshd_config

 | ListenAddress hostname


 When Fedora had such a setup, I had a lot of trouble with KRB5ized
 NFS4. See [1] for examples. Generally, external and internal DNS should
 be consistent.

 Beside this... afaik ${MACHINE} can contain '_' and '.' which are either
 forbidden ('_') or have special meanings in DNS.


 Enrico

 Footnotes:
 [1]  https://bugzilla.redhat.com/show_bug.cgi?id=648725
 --
 ___
 Openembedded-core mailing list
 Openembedded-core@lists.openembedded.org
 http://lists.openembedded.org/mailman/listinfo/openembedded-core


Thanks,

Sujith H

-- 
സുജിത് ഹരിദാസന്
Bangalore
ProjectContributor to KDE project
http://fci.wikia.com/wiki/Anti-DRM-Campaign
Blog http://sujithh.info
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-08-01 Thread Enrico Scholz
Otavio Salvador otavio-fkevb0iiklmbz+lybsd...@public.gmane.org writes:

 + echo 127.0.1.1  ${MACHINE}  ${D}${sysconfdir}/hosts

 This is a very questionable setup which causes a lot of harm.  When
 really wanted, it should be made optional and not the default.

 What kind of harm you see?

e.g. in sshd_config

| ListenAddress hostname


When Fedora had such a setup, I had a lot of trouble with KRB5ized
NFS4. See [1] for examples. Generally, external and internal DNS should
be consistent.

Beside this... afaik ${MACHINE} can contain '_' and '.' which are either
forbidden ('_') or have special meanings in DNS.


Enrico

Footnotes: 
[1]  https://bugzilla.redhat.com/show_bug.cgi?id=648725
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-07-31 Thread Sujith H
From: Sujith H sujith_harida...@mentor.com

If hostname is not added to /etc/hosts file then rpcinfo
command fails when hostname is passed as argument. This was
observed when rpcinfo command was tested on freescale target.
Below was the output observed without this change.

root@mx6q:~# rpcinfo -s mx6q
rpcinfo: can't contact rpcbind: RPC: (unknown error code)

Below is the output after this change:
root@mx6q:~# rpcinfo -s mx6q
   program version(s) netid(s) service owner
10  2,3,4 local,udp,tcp,udp6,tcp6  portmapper  superuser
root@mx6q:~#

Signed-off-by: Sujith H sujit...@gmail.com
---
 meta/recipes-core/netbase/netbase_5.2.bb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-core/netbase/netbase_5.2.bb 
b/meta/recipes-core/netbase/netbase_5.2.bb
index ab7ae65..a6fb010 100644
--- a/meta/recipes-core/netbase/netbase_5.2.bb
+++ b/meta/recipes-core/netbase/netbase_5.2.bb
@@ -18,6 +18,7 @@ do_install () {
install -m 0644 etc-rpc ${D}${sysconfdir}/rpc
install -m 0644 etc-protocols ${D}${sysconfdir}/protocols
install -m 0644 etc-services ${D}${sysconfdir}/services
+   echo 127.0.1.1  ${MACHINE}  ${D}${sysconfdir}/hosts
 }
 
 CONFFILES_${PN} = ${sysconfdir}/hosts
-- 
1.8.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-07-31 Thread Khem Raj
On Thu, Jul 31, 2014 at 7:59 AM, Sujith H sujit...@gmail.com wrote:
 +   echo 127.0.1.1  ${MACHINE}  ${D}${sysconfdir}/hosts

recipe will become MACHNE specific. Can this be done via post
processing funcs instead ?
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-07-31 Thread Mark Hatle

On 7/31/14, 10:42 AM, Khem Raj wrote:

On Thu, Jul 31, 2014 at 7:59 AM, Sujith H sujit...@gmail.com wrote:

+   echo 127.0.1.1  ${MACHINE}  ${D}${sysconfdir}/hosts


recipe will become MACHNE specific. Can this be done via post
processing funcs instead ?



I had the same comment.  We don't want to do this in the recipe itself.  Instead 
we want to likely add a rootfs/image configuration step, like the 
zap_root_password and similar actions.


This way it can be enabled/disabled more easily based on user requirements.

--Mark
--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-07-31 Thread Enrico Scholz
Sujith H sujith.h-re5jqeeqqe8avxtiumw...@public.gmane.org writes:

 + echo 127.0.1.1  ${MACHINE}  ${D}${sysconfdir}/hosts

This is a very questionable setup which causes a lot of harm.  When
really wanted, it should be made optional and not the default.



Enrico
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-07-31 Thread Otavio Salvador
On Thu, Jul 31, 2014 at 1:20 PM, Enrico Scholz
enrico.sch...@sigma-chemnitz.de wrote:
 Sujith H sujith.h-re5jqeeqqe8avxtiumw...@public.gmane.org writes:

 + echo 127.0.1.1  ${MACHINE}  ${D}${sysconfdir}/hosts

 This is a very questionable setup which causes a lot of harm.  When
 really wanted, it should be made optional and not the default.

What kind of harm you see?

I think moving this to postinst works for me and does not cause
problems I think.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] netbase: Adding loop back for machine name in hosts file

2014-07-31 Thread Mark Hatle

On 7/31/14, 3:44 PM, Otavio Salvador wrote:

On Thu, Jul 31, 2014 at 1:20 PM, Enrico Scholz
enrico.sch...@sigma-chemnitz.de wrote:

Sujith H sujith.h-re5jqeeqqe8avxtiumw...@public.gmane.org writes:


+ echo 127.0.1.1  ${MACHINE}  ${D}${sysconfdir}/hosts


This is a very questionable setup which causes a lot of harm.  When
really wanted, it should be made optional and not the default.


What kind of harm you see?

I think moving this to postinst works for me and does not cause
problems I think.



The only default configuration for 127.0.0.1 (not 1.1) should be localhost. 
Anything after that is installation independent and should be configured outside 
of the 'package' scope...


I recommend ROOTFS_POSTINSTALL_COMMAND...

--Mark
--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core