Permission problem when importing metadata

Hello,

I’ve made a full metadata export from a 2.17 snapshot, and am trying to import into a 2.18 database.

I let DHIS2 create an empty database. Then logging in as admin/district, I get messages like those below when trying to import. Any suggestions?

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.dataset.Section

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.validation.ValidationRule

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.user.User

···

Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

I let DHIS2 create an empty database. Then logging in as admin/district, I
get messages like those below when trying to import. Any suggestions?

Permission denied, you are not allowed to create objects of type class
org.hisp.dhis.dataset.Section
Permission denied, you are not allowed to create objects of type class
org.hisp.dhis.validation.ValidationRule
Permission denied, you are not allowed to create objects of type class
org.hisp.dhis.user.User

I seemed to have resolved this issue through first importing just orgunits,
then creating another user as Superuser and using that user for importing.

Knut

···

On Wed, Feb 25, 2015 at 8:51 AM, Knut Staring <knutst@gmail.com> wrote:

--
Knut Staring
Dept. of Informatics, University of Oslo
Norway: +4791880522
Skype: knutstar
http://dhis2.org

--
Knut Staring
Dept. of Informatics, University of Oslo
Norway: +4791880522
Skype: knutstar

Then it might mean that the admin/district does not have full Import/Export right which is completely rare if not tampered with from inception. It actually lists that the user does not have access to create data set section, validation rule and user‎. You are probably trying to import items you don’t have access to create.

Regards.

Sent from my BlackBerry 10 smartphone.

···

On Wed, Feb 25, 2015 at 8:51 AM, Knut Staring knutst@gmail.com wrote:

I let DHIS2 create an empty database. Then logging in as admin/district, I get messages like those below when trying to import. Any suggestions?

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.dataset.Section

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.validation.ValidationRule

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.user.User

I seemed to have resolved this issue through first importing just orgunits, then creating another user as Superuser and using that user for importing.

Knut

Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org


Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

Thanks, but this is probably rather linked to the fact that in an empty database, the admin superuser is not linked to any OrgUnit. So you first have to import orgunits and then link the admin user to the root, or probably better create another Superuser and rather log in as the new user before importing the rest of the metadata.

···

On Wed, Feb 25, 2015 at 12:46 PM, deemoyes@yahoo.com wrote:

Then it might mean that the admin/district does not have full Import/Export right which is completely rare if not tampered with from inception. It actually lists that the user does not have access to create data set section, validation rule and user‎. You are probably trying to import items you don’t have access to create.

Regards.

Sent from my BlackBerry 10 smartphone.

From: Knut Staring

Sent: Wednesday, 25 February 2015 03:51

To: dhis2-users@lists.launchpad.net

Subject: Re: [Dhis2-users] Permission problem when importing metadata


Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

On Wed, Feb 25, 2015 at 8:51 AM, Knut Staring knutst@gmail.com wrote:

I let DHIS2 create an empty database. Then logging in as admin/district, I get messages like those below when trying to import. Any suggestions?

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.dataset.Section

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.validation.ValidationRule

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.user.User

I seemed to have resolved this issue through first importing just orgunits, then creating another user as Superuser and using that user for importing.

Knut

Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org


Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

Oh true, database is empty. But once you have imported the org units already, the importer becomes the creator of the org units. This should still allow the admin/district ‎should be allowed to import more. But of course, another thing we need to check is that there has to be data elements in place before we can create validation rules too.

Maybe that explains why there is no access validation rule also.

Regards,

Adedayo

Sent from my BlackBerry 10 smartphone.

···

On Wed, Feb 25, 2015 at 12:46 PM, deemoyes@yahoo.com wrote:

Then it might mean that the admin/district does not have full Import/Export right which is completely rare if not tampered with from inception. It actually lists that the user does not have access to create data set section, validation rule and user‎. You are probably trying to import items you don’t have access to create.

Regards.

Sent from my BlackBerry 10 smartphone.

From: Knut Staring

Sent: Wednesday, 25 February 2015 03:51

To: dhis2-users@lists.launchpad.net

Subject: Re: [Dhis2-users] Permission problem when importing metadata


Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

On Wed, Feb 25, 2015 at 8:51 AM, Knut Staring knutst@gmail.com wrote:

I let DHIS2 create an empty database. Then logging in as admin/district, I get messages like those below when trying to import. Any suggestions?

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.dataset.Section

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.validation.ValidationRule

Permission denied, you are not allowed to create objects of type class org.hisp.dhis.user.User

I seemed to have resolved this issue through first importing just orgunits, then creating another user as Superuser and using that user for importing.

Knut

Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org


Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

Knut Staring

Dept. of Informatics, University of Oslo

Norway: +4791880522

Skype: knutstar

http://dhis2.org

Hi,

can you check if the user you are logged in as have authority to create
these objects? If you are working with meta-data on a system you have
"ownership" to its easier to log in as a user with the ALL authority.

Lars