#530 Building 389-ds-base source produces error message: ./.libs/libslapd.so: undefined reference to .....
Closed: wontfix 7 years ago Opened 11 years ago by rmeggins.

https://bugzilla.redhat.com/show_bug.cgi?id=882393 (Fedora)

Description of problem:
More  ./.libs/libslapd.so: undefined reference to nss symbols appear when
building 389-ds-base-1.3.0.a1 on OpenSuse 12.1 64 bit.


Version-Release number of selected component (if applicable):
389-ds-base-1.2.11.15 and 389-ds-base-1.3.0.a1

How reproducible:

Steps to Reproduce:
1. Install all prerequisites for 64 bit platforms as per
http://directory.fedoraproject.org/wiki/Building.

2.
COnfigure 389-ds-base with command:
./configure
--prefix=/usr/local/pkgs/389_ds_components/389-ds-base-1.2.11.15/ds-base
--enable-debug=yes --with-gnu-ld=yes
            --with-systemdsystemunitdir=/usr/local/pkgs/389_ds_components/389-d
s-base-1.2.11.15/confdirs/systemdsystemunitdir
            --with-systemdsystemconfdir=/usr/local/pkgs/389_ds_components/389-d
s-base-1.2.11.15/confdirs/systemdsystemconfdir
            --with-instconfigdir=/usr/local/pkgs/389_ds_components/389-ds-base-
1.2.11.15/confdirs/instconfigdir
            --with-nspr=/usr/local/pkgs/389_ds_depencences/nspr-4.9.3
            --with-nss=/usr/local/pkgs/389_ds_depencences/nss-3.14
            --with-nss-inc=/usr/local/pkgs/389_ds_depencences/nss-3.14/include
            --with-nss-lib=/usr/local/pkgs/389_ds_depencences/nss-3.14/lib
--with-openldap=/usr/local/pkgs/openldap-2.4.33_389_directory_server
            --with-openldap-inc=/usr/local/pkgs/openldap-2.4.33_389_directory_s
erver/include
--with-openldap-lib=/usr/local/pkgs/openldap-2.4.33_389_directory_server/lib64
--with-openldap-bin=/usr/local/pkgs/openldap-2.4.33_389_directory_server/bin
            --with-svrcore=/usr/local/pkgs/389_ds_depencences/svrcore-4.0.4
            --with-icu=/usr/local/pkgs/389_ds_depencences/icu4c-50_1
            --with-netsnmp=/usr/local/pkgs/389_ds_depencences/net-snmp-5.7.2
--with-netsnmp-inc=/usr/local/pkgs/389_ds_depencences/net-snmp-5.7.2/include
--with-netsnmp-lib=/usr/local/pkgs/389_ds_depencences/net-snmp-5.7.2/lib64
            --with-kerberos=/usr/local/pkgs/389_ds_depencences/krb5-1.10.3
            --with-pcre=/usr/local/pkgs/389_ds_depencences/pcre-8.32

3.
make

Actual results:
..............................................
/bin/sh ./libtool --tag=CC   --mode=link gcc  -g -O2   -o migratecred-bin
ldap/servers/slapd/tools/migratecred_bin-migratecred.o libslapd.la
      -L/usr/local/pkgs/389_ds_depencences/nspr-4.9.3/lib64 -lplc4 -lplds4
-lnspr4 -L/usr/local/pkgs/389_ds_depencences/nss-3.14/lib -lssl3 -lnss3
      -L/usr/local/pkgs/389_ds_depencences/svrcore-4.0.4/lib64 -lsvrcore
-L/usr/local/pkgs/openldap-2.4.33_389_directory_server/lib64 -lldap_r  -llber
-lsasl2
libtool: link: gcc -g -O2 -o .libs/migratecred-bin
ldap/servers/slapd/tools/migratecred_bin-migratecred.o  ./.libs/libslapd.so
      -L/usr/local/pkgs/openldap-2.4.33_389_directory_server/lib64
-L/usr/local/pkgs/389_ds_depencences/svrcore-4.0.4/lib64
      -L/usr/local/pkgs/389_ds_depencences/nss-3.14/lib
-L/usr/local/pkgs/389_ds_depencences/nspr-4.9.3/lib64
-L/usr/local/pkgs/389_ds_depencences/krb5-1.10.3/lib64
      -L/usr/local/pkgs/389_ds_depencences/pcre-8.32/lib64 -lkrb5 -lk5crypto
-lcom_err /usr/local/pkgs/389_ds_depencences/pcre-8.32/lib64/libpcre.so
-lpthread
      /usr/local/pkgs/389_ds_depencences/svrcore-4.0.4/lib64/libsvrcore.so
-lssl3 -lnss3 -lplds4 -lplc4 -lnspr4
      /usr/local/pkgs/openldap-2.4.33_389_directory_server/lib64/libldap_r.so
-lssl -lcrypto
/usr/local/pkgs/openldap-2.4.33_389_directory_server/lib64/liblber.so
      -lresolv -lsasl2 -pthread -Wl,-rpath -Wl,/usr/local/pkgs/389_ds_component
s/389-ds-base-1.2.11.15/ds-base/lib64/dirsrv
      -Wl,-rpath -Wl,/usr/local/pkgs/389_ds_depencences/pcre-8.32/lib64
-Wl,-rpath -Wl,/usr/local/pkgs/389_ds_depencences/svrcore-4.0.4/lib64
      -Wl,-rpath -Wl,/usr/local/pkgs/openldap-2.4.33_389_directory_server/lib64
./.libs/libslapd.so: undefined reference to `MD5_HashBuf'
./.libs/libslapd.so: undefined reference to `SEED_DestroyContext'
./.libs/libslapd.so: undefined reference to `Camellia_InitContext'
./.libs/libslapd.so: undefined reference to `Camellia_Encrypt'
./.libs/libslapd.so: undefined reference to `SEED_Decrypt'
./.libs/libslapd.so: undefined reference to `MD5_Begin'
./.libs/libslapd.so: undefined reference to `SHA1_End'
./.libs/libslapd.so: undefined reference to `RC2_InitContext'
./.libs/libslapd.so: undefined reference to `AES_Decrypt'
./.libs/libslapd.so: undefined reference to `Camellia_DestroyContext'
./.libs/libslapd.so: undefined reference to `HMAC_Begin'
./.libs/libslapd.so: undefined reference to `SHA1_Clone'
./.libs/libslapd.so: undefined reference to `MD5_Clone'
./.libs/libslapd.so: undefined reference to `RC2_Decrypt'
./.libs/libslapd.so: undefined reference to `AES_DestroyContext'
./.libs/libslapd.so: undefined reference to `AES_Encrypt'
./.libs/libslapd.so: undefined reference to `RC2_DestroyContext'
./.libs/libslapd.so: undefined reference to `TLS_PRF'
./.libs/libslapd.so: undefined reference to `Camellia_Decrypt'
./.libs/libslapd.so: undefined reference to `RC4_DestroyContext'
./.libs/libslapd.so: undefined reference to `SEED_InitContext'
./.libs/libslapd.so: undefined reference to `BL_Unload'
./.libs/libslapd.so: undefined reference to `RC4_Decrypt'
./.libs/libslapd.so: undefined reference to `RC4_InitContext'
./.libs/libslapd.so: undefined reference to `AES_InitContext'
./.libs/libslapd.so: undefined reference to `SEED_Encrypt'
./.libs/libslapd.so: undefined reference to `MD5_End'
./.libs/libslapd.so: undefined reference to `SHA1_Begin'
./.libs/libslapd.so: undefined reference to `RC4_Encrypt'
./.libs/libslapd.so: undefined reference to `DES_Decrypt'
./.libs/libslapd.so: undefined reference to `DES_Encrypt'
./.libs/libslapd.so: undefined reference to `DES_DestroyContext'
./.libs/libslapd.so: undefined reference to `RC2_Encrypt'
./.libs/libslapd.so: undefined reference to `MD5_DestroyContext'
./.libs/libslapd.so: undefined reference to `DES_InitContext'
./.libs/libslapd.so: undefined reference to `HMAC_Destroy'
./.libs/libslapd.so: undefined reference to `SHA1_HashBuf'
./.libs/libslapd.so: undefined reference to `SHA256_HashBuf'
./.libs/libslapd.so: undefined reference to `HASH_GetRawHashObject'
./.libs/libslapd.so: undefined reference to `HMAC_Finish'
./.libs/libslapd.so: undefined reference to `SHA1_DestroyContext'
collect2: ld returned 1 exit status
make[1]: *** [migratecred-bin] Error 1



Expected results:
The symbols should be found in nss library but they are not.

Additional info:
Read some info from:
http://www.sourceware.org/autobook/autobook/autobook_88.html#SEC88 so I tried
using libslapd_la_LDFLAGS = -no-undefined but the result was the same.

At: http://www.sourceware.org/autobook/autobook/autobook_172.html#SEC172 they
say that:
`-no-undefined'
This is an extremely important option when you are aiming for maximum
portability. It declares that all of the symbols required by the target are
resolved at link time. Some shared library architectures do not allow undefined
symbols by default (Tru64 Unix), and others do not allow them at all (AIX). By
using this switch, and ensuring that all symbols really are resolved at link
time, your libraries will work on even these platforms. See section 11.2.1
Creating Libtool Libraries with Automake.

I also read this one:
http://www.gnu.org/software/libtool/manual/html_node/Inter_002dlibrary-dependen
cies.html and tried to remake libslapd.so playing around with rpath and -lnss3
in different places in the libtool link command.


Also read ltmain.sh and saw this one:

func_mode_link ()
{
    $opt_debug
    case $host in
    *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
      # It is impossible to link a dll without this setting, and
      # we shouldn't force the makefile maintainer to figure out
      # which system we are compiling for in order to pass an extra
      # flag for every libtool invocation.
      # allow_undefined=no

      # FIXME: Unfortunately, there are problems with the above when trying
      # to make a dll which has undefined symbols, in which case not
      # even a static library is built.  For now, we need to specify
      # -no-undefined on the libtool link line when we can be certain
      # that all symbols are satisfied, otherwise we get a static library.
      allow_undefined=yes
....................
}

Also I searched some symbols in nss source code and found them defined in
mozilla/security/nss/lib/freebl/loader.c so I added -lfreebl3 at the NSS_LINK
in Makefile.am but the result was the same.

Can someone give me a clue what could be the propblem?

Thanks,
Steve

Looks like this is the problem:
Makefile.am:
{{{
NSS_LINK = @nss_lib@ -lssl3 -lnss3
}}}
but
{{{

pkg-config --libs nss

-lssl3 -lsmime3 -lnss3 -lnssutil3 -lplds4 -lplc4 -lnspr4 -lpthread -ldl
}}}
So it looks as though we need to add -lnssutil3 to NSS_LINK

No that did not solve my problem.
Changed NSS_LINK to NSS_LINK = @nss_lib@ -lssl3 -lnss3 -lnssutil3 in Makefile.am and Makefile.in; make distclean; reconfigure;make. Same result obtained.
I will try witl all the libs in the pkg-config output and see what happens.

No, it seems it is not working. Do you have other ideas that I could try?

Thanks,
Steve.

Maybe order is significant? Try putting the NSS links near the end, after the libldap_r.so and liblber.so links, followed by the NSPR links, followed by system links such as -lpthread and -ldl

Indeed it was a problem with the libraries. I added path to my nss libraries when linking libslapd.so with -L/path and that solved my problem.

But now I have another problem at "make" stage:
....................................................................
make[1]: *** No rule to make target ldap/ldif/90betxn-plugins.ldif', needed byall-am'. Stop.

Do you have any suggestions for what could be the cause here?

Thanks,
Steve.

Replying to [comment:5 stevegreg]:

Indeed it was a problem with the libraries. I added path to my nss libraries when linking libslapd.so with -L/path and that solved my problem.

I don't understand. Can you be more specific? This is your original build path:
{{{
-L/usr/local/pkgs/389_ds_depencences/nss-3.14/lib
}}}

Was this path not correct?

But now I have another problem at "make" stage:
....................................................................
make[1]: *** No rule to make target ldap/ldif/90betxn-plugins.ldif', needed byall-am'. Stop.

Do you have any suggestions for what could be the cause here?

Does the file ldap/ldif/90betxn-plugins.ldif exist? Are you using the latest source from git master branch?

Thanks,
Steve.

Yes, -L/path was referring to "-L/usr/local/pkgs/389_ds_depencences/nss-3.14/lib"

I use 389-ds-base-1.3.0.a1 and it seems the problem was not solved by adding -L/path but was introducing another one (this with 90betxn-plugins.ldif) before. I commented 90betxn-plugins.ldif from Makefile.am and Makefile.in and get back to my previous error.

ldap/ldif/90betxn-plugins.ldif file does not exist. Should it be there by default or it is created by make?

I belive something is messed up really seriously at my workstation.

From http://directory.fedoraproject.org/wiki/Building#NSS it says:
configure attempts to find all of the dependent components using pkg-config (e.g. pkg-config --libs nspr) or using the component specific script (e.g. net-snmp-config or icu-config).

But running:
pkg-config --libs nspr, gives me:
Package nspr was not found in the pkg-config search path.
Perhaps you should add the directory containing `nspr.pc'
to the PKG_CONFIG_PATH environment variable
No package 'nspr' found
This may be a cause for not having the paths solved by default. Maybe I should try to solve this problem first.

Replying to [comment:7 stevegreg]:

Yes, -L/path was referring to "-L/usr/local/pkgs/389_ds_depencences/nss-3.14/lib"

I use 389-ds-base-1.3.0.a1 and it seems the problem was not solved by adding -L/path but was introducing another one (this with 90betxn-plugins.ldif) before. I commented 90betxn-plugins.ldif from Makefile.am and Makefile.in and get back to my previous error.

ldap/ldif/90betxn-plugins.ldif file does not exist. Should it be there by default or it is created by make?

It is in the upstream source:
master branch - http://git.fedorahosted.org/cgit/389/ds.git/tree/ldap/ldif/90betxn-plugins.ldif
1.2.11 branch - http://git.fedorahosted.org/cgit/389/ds.git/tree/ldap/ldif/90betxn-plugins.ldif?h=389-ds-base-1.2.11

I don't know why you don't have this file.

I belive something is messed up really seriously at my workstation.

From http://directory.fedoraproject.org/wiki/Building#NSS it says:
configure attempts to find all of the dependent components using pkg-config (e.g. pkg-config --libs nspr) or using the component specific script (e.g. net-snmp-config or icu-config).

Right. It attempts if you don't specify --with-nspr, --with-nss, etc.

But running:
pkg-config --libs nspr, gives me:
Package nspr was not found in the pkg-config search path.
Perhaps you should add the directory containing `nspr.pc'
to the PKG_CONFIG_PATH environment variable
No package 'nspr' found
This may be a cause for not having the paths solved by default. Maybe I should try to solve this problem first.

No - your previous messages indicate that you are attempting to build all of the components from source - you would typically only use pkg-config to use the -devel or -dev package provided by your distribution.

I believe it worked now. The ldap/ldif/90betxn-plugins.ldif file was missing becouse I was given "make distclean" and it seems this deletes more files than it should.

I solved the problem by recreating the .libs/libslapd.so.0.0.0 library and its symbolic links by adding to the link line -Wl,-rpath -Wl,path to nss and -Wl,-rpath -Wl,path to nspr and also adding "-lfreebl -lfreebl3" link libraries.

I succeeded to compile and install 389-ds-base, will try to install the consoles too and 389-admin and 389-adminutil and give it a try to see if something works in the end.

Will come back if get more trouble with the rest.

Thanks,
Steve.

I installed everithing and run ./setup-ds-admin.pl. I used:
............................................................
Computer name [linux-6ytl.example.com]: localhost

WARNING: There are problems with the hostname.
The hostname 'localhost' does not look like a
fully qualified host and domain name.

Please check the spelling of the hostname and/or your network configuration.
If you proceed with this hostname, you may encounter problems.

Do you want to proceed with hostname 'localhost'? [no]: yes
............................................................
If you want to configure the Administration Server to bind
to a specific IP address, enter the address below.

IP address [0.0.0.0]: 127.0.0.1
............................................................
The interactive phase is complete. The script will now set up your
servers. Enter No or go Back if you want to change something.

Are you ready to set up your servers? [yes]:
Creating directory server . . .
Warning: hostname localhost is not a fully qualified host and domain name
Failed to issue method call: Unit dirsrv at localhost.service (Unit dirsrv@localhost.service ) failed to load:
No such file or directory.
See system logs and 'systemctl status dirsrv@localhost.service' for details.
Attempting to obtain server status . . .
Attempting to obtain server status . . .
Attempting to obtain server status . . .
Error: Could not read error log /usr/local/pkgs/389_ds_components/389-ds-base-1.3.0.a1-nss_3_14-nspr_4.9.4/ds-base/var/log/dirsrv/slapd-localhost/errors to get server startup status. Error: No such file or directory
Could not start the directory server using command '/bin/systemctl start dirsrv@localhost.service'. The last line from the error log was 'no status'. Error: No such file or directory
Error: Could not create directory server instance 'localhost'.
Exiting . . .
Log file is '/tmp/setupl6Ozb6.log'

I will try to resolve with the hostname to be a FQDN, but meanwhile I want to ask if you could tell me something about the error above:
Failed to issue method call: Unit dirsrv at localhost.service (Unit dirsrv@localhost.service ) failed to load: No such file or directory.

I tried:

linux-6ytl:~ # systemctl status dirsrv@localhost.service
dirsrv at localhost.service
Loaded: error (Reason: No such file or directory)
Active: inactive (dead)
linux-6ytl:~ #
linux-6ytl:~ # systemctl status dirsrv at localhost
Failed to issue method call: Unit name dirsrv@localhost is not valid.
linux-6ytl:~ #

What configure flags did you use?
Does /usr/local/pkgs/389_ds_components/389-ds-base-1.3.0.a1-nss_3_14-nspr_4.9.4/ds-base/var/log/dirsrv/slapd-localhost/errors exist? If so, what are the permissions?

For 389-admin-1.1.30 I used the following command to configure it:
./configure --prefix=/usr/local/pkgs/389_ds_components/389-admin-1.1.30 --enable-debug --enable-rpath --enable-threading
--with-gnu-ld --with-httpd=/usr/local/pkgs/httpd-2.4.3_389_directory_server/bin/httpd
--with-nspr=/usr/local/pkgs/389_ds_depencences/nspr-4.9.4
--with-nss=/usr/local/pkgs/389_ds_depencences/nss-3.14_with_nspr_4.9.4
--with-openldap=/usr/local/pkgs/openldap-2.4.33_389_directory_server
--with-icu=/usr/local/pkgs/389_ds_depencences/icu4c-50_1
--with-adminutil=/usr/local/pkgs/389_ds_components/389-adminutil-1.1.14
--with-apxs=/usr/local/pkgs/httpd-2.4.3_389_directory_server/bin/apxs
--with-apr-config=/usr/local/pkgs/apr-1.4.6/bin/apr-1-config

File "/usr/local/pkgs/389_ds_components/389-ds-base-1.3.0.a1-nss_3_14-nspr_4.9.4/ds-base/var/log/dirsrv/slapd-localhost/errors" does not exist.

ok - what about 389-ds-base? What configure arguments did you use? I'm curious as to why it is attempting to use systemd?

For 389-ds-base I used this:
./configure --prefix=/usr/local/pkgs/389_ds_components/389-ds-base-1.3.0.a1-nss_3_14-nspr_4.9.4/ds-base
--enable-debug=yes --with-gnu-ld=yes
--with-systemdsystemunitdir=/usr/local/pkgs/389_ds_components/389-ds-base-1.3.0.a1-nss_3_14-nspr_4.9.4/confdirs/systemdsystemunitdir
--with-systemdsystemconfdir=/usr/local/pkgs/389_ds_components/389-ds-base-1.3.0.a1-nss_3_14-nspr_4.9.4/confdirs/systemdsystemconfdir
--with-instconfigdir=/usr/local/pkgs/389_ds_components/389-ds-base-1.3.0.a1-nss_3_14-nspr_4.9.4/confdirs/instconfigdir
--with-nspr=/usr/local/pkgs/389_ds_depencences/nspr-4.9.4
--with-nss=/usr/local/pkgs/389_ds_depencences/nss-3.14_with_nspr_4.9.4
--with-nss-inc=/usr/local/pkgs/389_ds_depencences/nss-3.14_with_nspr_4.9.4/include
--with-nss-lib=/usr/local/pkgs/389_ds_depencences/nss-3.14_with_nspr_4.9.4/lib
--with-openldap=/usr/local/pkgs/openldap-2.4.33_389_directory_server
--with-openldap-inc=/usr/local/pkgs/openldap-2.4.33_389_directory_server/include
--with-openldap-lib=/usr/local/pkgs/openldap-2.4.33_389_directory_server/lib64
--with-openldap-bin=/usr/local/pkgs/openldap-2.4.33_389_directory_server/bin
--with-svrcore=/usr/local/pkgs/389_ds_depencences/svrcore-4.0.4
--with-icu=/usr/local/pkgs/389_ds_depencences/icu4c-50_1
--with-netsnmp=/usr/local/pkgs/389_ds_depencences/net-snmp-5.7.2
--with-netsnmp-inc=/usr/local/pkgs/389_ds_depencences/net-snmp-5.7.2/include
--with-netsnmp-lib=/usr/local/pkgs/389_ds_depencences/net-snmp-5.7.2/lib64
--with-kerberos=/usr/local/pkgs/389_ds_depencences/krb5-1.10.3
--with-pcre=/usr/local/pkgs/389_ds_depencences/pcre-8.32

You only need to use systemd if you plan on installing 389 using operating system paths like /etc /usr etc. Otherwise, use --with-systemdsystemunitdir=no --with-systemdsystemconfdir=no --with-tmpfiles-d=no

You'll also need to specify those to build 389-admin

When you configure 389-admin, you will need to specify the same prefix as with ds-base

That worked for me. I also had to remove --with-instconfigdir option from 389-ds-base configure command as it was a problem with the schema folder and files being created in their default location instead of path in --with-instconfigdir.

I successfully run setup-ds-admin.pl and hope all goes easily from now on.

Thank you very much.

Hi Richard,
I have another problem starting 389-console.

I get the following error:
linux-6ytl:/usr/share/java # ./389-console
Error: Could not find or load main class com.netscape.management.client.console.Console

For building the console components I used a precompiled version of java: jdk1.7.0_09
The first time I wanted to start the 389-console the message was saying that it could not find main class com.netscape.management.client.console.Console and a backtrace was displayed on the screen. But then I changed the path to point to the right java package like this:
export PATH=/windows/SG_GoFlex_W2/Prjc/jdk1.7.0_09/bin:$PATH
and then I had no backtrace displayed, only the message above. I believe it can not load the console main class this time but I can not figure out how to solve this. I also set export JAVA_HOME=/windows/SG_GoFlex_W2/Prjc/jdk1.7.0_09/ but that was not solving my problem.

Searcing for "com.netscape.management.client.console.Console" in install location:
linux-6ytl:/usr/local/pkgs/389_ds_components/idm-console-framework-1.1.7/release/jars # grep -n -r "com.netscape.management.client.console.Console" *
Binary file idm-console-base-1.1.7.jar matches
Binary file idm-console-mcc-1.1.7.jar matches
linux-6ytl:/usr/local/pkgs/389_ds_components/idm-console-framework-1.1.7/release/jars #

Same result is for searching in /usr/share/java.
I must say that in /usr/share/java I performed:
linux-6ytl:/usr/share/java # ln -s 389-console-1.1.7_en.jar 389-console.jar
before installing 389-console. Making symbolic link
linux-6ytl:/usr/share/java # ln -s 389-console-1.1.7.jar 389-console.jar
was giving another not found exception (Exception in thread "main" java.lang.NoClassDefFoundError: com/netscape/management/nmclf/SuiLookAndFeel
) that I could get rid of it by linking against _en.jar version.

Can you give me a suggestion for solving this error?

Thank you,
Steve.

I found the problem. Just had to add path to Console.class file to 389-console script.

Metadata Update from @stevegreg:
- Issue assigned to rmeggins
- Issue set to the milestone: FUTURE

7 years ago

Metadata Update from @firstyear:
- Custom field reviewstatus adjusted to new (was: Needs Review)
- Issue close_status updated to: worksforme
- Issue status updated to: Closed (was: Open)

7 years ago

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This issue has been cloned to Github and is available here:
- https://github.com/389ds/389-ds-base/issues/530

If you want to receive further updates on the issue, please navigate to the github issue
and click on subscribe button.

Thank you for understanding. We apologize for all inconvenience.

Metadata Update from @spichugi:
- Issue close_status updated to: wontfix (was: worksforme)

3 years ago

Login to comment on this ticket.

Metadata