dbTalk Databases Forums  

[Info-Ingres] createdb -r flag

comp.databases.ingres comp.databases.ingres


Discuss [Info-Ingres] createdb -r flag in the comp.databases.ingres forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Martin Bowes
 
Posts: n/a

Default [Info-Ingres] createdb -r flag - 05-28-2010 , 03:51 AM






Hi All,



Has anyone got any experience with the createdb -rlocation_name flag?
Care to share some insights?



I've been hacking around trying to make sense of the manuals description
and getting no where fast.



Martin Bowes

Reply With Quote
  #2  
Old   
Paul Mason
 
Posts: n/a

Default Re: [Info-Ingres] createdb -r flag - 05-28-2010 , 04:22 AM






Hi Marty,



Given that I have a ServiceDesk issue with you that relates to this you
won't be surprised to hear that I have some experience with this.



-r is for creating a "read-only" database. This is something that was
introduced in 2.5 I think and is a way to e.g. distribute a database on
a CDROM.



Let's take the CD-ROM example. So you create a normal database on a
regular location:



Createdb sales_demo



You populate it with whatever tables and other objects you want. Next
you copy the ingres/data/default/sales_demo directory structure to your
CD-ROM.



OK so let's say you now take that CD-ROM with you, load it in another
machine and want to use the sales_demo database. Obviously you'll have
to have the same version of Ingres installed. You'll also need to mount
the CD - so let's say that's /mnt/cdrom. Now you create an ingres
location that points to /mnt/cdrom - let's say 'cdrom_loc' and then you
create a database:



Createdb -rcdrom_loc sales_demo



The -r tells ingres that this is a read-only database and that all the
files for it already exist under the cdrom_loc location.



Read-only databases are only allowed to have 1 location. Also we could
have changed the name of the database so long as we'd changed the name
of the data directory when we copied it to CD-ROM. In fact if you're
testing this within a single installation (as we do) then you'd need to
do this to avoid conflicts.



Hope this helps.

Regards

Paul



From: info-ingres-bounces (AT) kettleriver...ting (DOT) com
[mailto:info-ingres-bounces (AT) kettleriverconsulting (DOT) com] On Behalf Of
Martin Bowes
Sent: 28 May 2010 09:52
To: Ingres and related product discussion forum
Subject: [Info-Ingres] createdb -r flag



Hi All,



Has anyone got any experience with the createdb -rlocation_name flag?
Care to share some insights?



I've been hacking around trying to make sense of the manuals description
and getting no where fast.



Martin Bowes

Reply With Quote
  #3  
Old   
Martin Bowes
 
Posts: n/a

Default Re: [Info-Ingres] createdb -r flag - 05-28-2010 , 09:31 AM



OK. Done that....looks OK.



But if I stay in a single installation and change the name of the
database, when I do an infodb it picks up the fact that the config file
was created on a different database.



Marty



From: Paul Mason [mailto:Paul.Mason (AT) ingres (DOT) com]
Sent: 28 May 2010 10:22
To: Ingres and related product discussion forum
Subject: Re: [Info-Ingres] createdb -r flag



Hi Marty,



Given that I have a ServiceDesk issue with you that relates to this you
won't be surprised to hear that I have some experience with this.



-r is for creating a "read-only" database. This is something that was
introduced in 2.5 I think and is a way to e.g. distribute a database on
a CDROM.



Let's take the CD-ROM example. So you create a normal database on a
regular location:



Createdb sales_demo



You populate it with whatever tables and other objects you want. Next
you copy the ingres/data/default/sales_demo directory structure to your
CD-ROM.



OK so let's say you now take that CD-ROM with you, load it in another
machine and want to use the sales_demo database. Obviously you'll have
to have the same version of Ingres installed. You'll also need to mount
the CD - so let's say that's /mnt/cdrom. Now you create an ingres
location that points to /mnt/cdrom - let's say 'cdrom_loc' and then you
create a database:



Createdb -rcdrom_loc sales_demo



The -r tells ingres that this is a read-only database and that all the
files for it already exist under the cdrom_loc location.



Read-only databases are only allowed to have 1 location. Also we could
have changed the name of the database so long as we'd changed the name
of the data directory when we copied it to CD-ROM. In fact if you're
testing this within a single installation (as we do) then you'd need to
do this to avoid conflicts.



Hope this helps.

Regards

Paul



From: info-ingres-bounces (AT) kettleriver...ting (DOT) com
[mailto:info-ingres-bounces (AT) kettleriverconsulting (DOT) com] On Behalf Of
Martin Bowes
Sent: 28 May 2010 09:52
To: Ingres and related product discussion forum
Subject: [Info-Ingres] createdb -r flag



Hi All,



Has anyone got any experience with the createdb -rlocation_name flag?
Care to share some insights?



I've been hacking around trying to make sense of the manuals description
and getting no where fast.



Martin Bowes

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.