Re: Upgrading the Installed package

2008-02-06 Thread शंतनु (Shantanoo)
On Feb 6, 2008 11:41 AM, navneet Upadhyay [EMAIL PROTECTED] wrote:
 Hi,
   I have two binary packages of an application of version 1.1 and 1.2.
 *The 1.1 is already installed, how can i upgrade it to 1.2* ?

 Do i have to uninstall 1.1 and then install 1.2 ?   I would prefer a way by
 which i can upgrade an wxisting package without uninstalling.


You may try portupgrade which can handle upgrades for you.

more info on: http://www.onlamp.com/pub/a/bsd/2003/08/28/FreeBSD_Basics.html


regards,
shantanoo
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Upgrading the Installed package

2008-02-06 Thread Jeremy Chadwick
On Wed, Feb 06, 2008 at 02:10:19PM +0530, ??? (Shantanoo) wrote:
 On Feb 6, 2008 11:41 AM, navneet Upadhyay [EMAIL PROTECTED] wrote:
  Hi,
I have two binary packages of an application of version 1.1 and 1.2.
  *The 1.1 is already installed, how can i upgrade it to 1.2* ?
 
  Do i have to uninstall 1.1 and then install 1.2 ?   I would prefer a way by
  which i can upgrade an wxisting package without uninstalling.
 
 
 You may try portupgrade which can handle upgrades for you.
 more info on: http://www.onlamp.com/pub/a/bsd/2003/08/28/FreeBSD_Basics.html

Sigh... why do people always recommend portupgrade to users without
telling them of the caveats?  I grow tired of this.  So let's tell
Navneet exactly what he's getting into, shall we?

portupgrade:
  - Written in Ruby, which not many UNIX admins are familiar with
(compared to, say, perl).  If portupgrade has a bug, you will need
to speak Ruby.
  - Ruby is not included in the base system; you have to install it
from ports (read: just another thing to have to maintain...)

ports base system:
  - C-based, and includes all of the pkg_* utilities.  Nearly every
FreeBSD user/administrator is familiar with these tools.
  - gcc comes with the base system.

portupgrade:
  - Maintains its own database of ports installed, dependencies, and
so on -- COMPLETELY separate from that of the ports base system.
  - Said database must be kept in sync with ports base system
dependencies and other whatnots; and if they go out of sync (which
happens regularly as can be confirmed by the never-ending supply of
posts to freebsd-ports@ about portupgrade problems), you get to
read incredibly cryptic error messages from Ruby.
  - Said database is Berkeley DB-based, which means you have to install
Oracle/Sleepycat BDB from ports.  (I believe you can pick DB1.x
which comes with libc, but it's not recommended due to bugs).

ports base system:
  - Uses flat text files in /var/db/pkg and /var/db/ports.

The reason portupgrade uses its own database is supposedly due to the
shortcomings/oversights of the existing ports system, and that's a
legitimate point..  But my opinion is that these shortcomings/oversights
should be addressed in the ports system and not via some third-party
tool which adds unnecessary complexities and more headaches.

Thus, I would suggest people go with the KISS (Keep It Simple, Stupid!)
method, and consider using tools which are written in languages which
come with the base system (e.g. C or sh) -- but even more importantly,
use and rely solely on the ports base system.

One such tool is portmaster (ports-mgmt/portmaster), maintained by Doug
Barton.  It's actively maintained and written in sh.  Its author is
quite active with freebsd-ports, and is quick to respond to both bug
reports and feature requests.

-- 
| Jeremy Chadwickjdc at parodius.com |
| Parodius Networking   http://www.parodius.com/ |
| UNIX Systems Administrator  Mountain View, CA, USA |
| Making life hard for others since 1977.  PGP: 4BD6C0CB |

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Upgrading the Installed package

2008-02-06 Thread Wojciech Puchar
while i usually did this think manually i would try portmaster next time i 
will need an upgrade. and - thanks to your explanation - i will avoid 
portupgrade.


thank you.



One such tool is portmaster (ports-mgmt/portmaster), maintained by Doug
Barton.  It's actively maintained and written in sh.  Its author is
quite active with freebsd-ports, and is quick to respond to both bug
reports and feature requests.

--
| Jeremy Chadwickjdc at parodius.com |
| Parodius Networking   http://www.parodius.com/ |
| UNIX Systems Administrator  Mountain View, CA, USA |
| Making life hard for others since 1977.  PGP: 4BD6C0CB |

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]



___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Upgrading the Installed package

2008-02-06 Thread Jason C. Wells

navneet Upadhyay wrote:

Hi,
  I have two binary packages of an application of version 1.1 and 1.2.
*The 1.1 is already installed, how can i upgrade it to 1.2* ?

Do i have to uninstall 1.1 and then install 1.2 ?   I would prefer a way by
which i can upgrade an wxisting package without uninstalling.


Uninstall reinstall takes all of five seconds.  It's quite easy.  Any of 
the ports management software has to do some variety of this anyway. 
The only difference is they do it with one command.


#!/bin/sh
pkg_delete pkg-1.1
pkg_add pkg-1.2

There!  A new port management binary upgrade utility.

The usefulness of the port management apps (portmaster,portupgrade) is 
when you want to upgrade multiple ports and large amounts of 
dependencies all at once.  They are more trouble than they are worth for 
a single package. That is, unless you are already using them.


Regards,
Jason

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Upgrading the Installed package

2008-02-06 Thread Alex Zbyslaw

Jason C. Wells wrote:


navneet Upadhyay wrote:


Hi,
  I have two binary packages of an application of version 1.1 and 
1.2.

*The 1.1 is already installed, how can i upgrade it to 1.2* ?

Do i have to uninstall 1.1 and then install 1.2 ?   I would prefer a 
way by

which i can upgrade an wxisting package without uninstalling.



Uninstall reinstall takes all of five seconds.  It's quite easy.  Any 
of the ports management software has to do some variety of this 
anyway. The only difference is they do it with one command.


Actually, there is one other key difference.  portupgrade[1] will make a 
*backup* of the package it is about to uninstall, and will recover that 
backup if the subsequent install of the new package fails.  You can do 
that by hand with the pkg_ tools but I know I prefer it to just happen.  
You could add that to your script, but why re-invent the wheel?


portupgrade[1] also keeps copies of any libraries it uninstalls during 
an upgrade, which ought not to be necessary.  But if something was 
silently relying on one, you won't break it.


The usefulness of the port management apps (portmaster,portupgrade) is 
when you want to upgrade multiple ports and large amounts of 
dependencies all at once.  They are more trouble than they are worth 
for a single package. That is, unless you are already using them.


The other argument would be that there's no better time to get familiar 
with a tool than when you can use it to do something easy.


--Alex

[1] portmaster may do this too.  I don't know as regrettably I haven't 
found time to try it yet.  The new version is something I would like to 
try, and while I can't recommend it from personal experience, I would 
suggest trying it nonetheless.




___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Upgrading the Installed package

2008-02-06 Thread Matthew D. Fuller
On Wed, Feb 06, 2008 at 01:51:33AM -0800 I heard the voice of
Jeremy Chadwick, and lo! it spake thus:
 
 So let's tell Navneet exactly what he's getting into, shall we?

OK, but let's do that by telling him what he's getting into, not vague
gestures at overblown half-truths.


   - Ruby is not included in the base system; you have to install it
 from ports (read: just another thing to have to maintain...)

My workstation has about 800 ports installed.  A relatively lean
server has 300.  1 more is so deep in the noise, you can't hardly
measure it, much less see it.


 ports base system:
   - C-based, and includes all of the pkg_* utilities.  Nearly every
 FreeBSD user/administrator is familiar with these tools.

Can't upgrade things.  Show me how I use pkg_* to upgrade a package
(let's say, gtk), and have all the metadata set right afterward.

Requires either stupid amounts of manual work, or a lot of scripting
(I upgrade perl.  How do I rebuild p5-*?).


 portupgrade:
   - Maintains its own database of ports installed, dependencies, and
 so on -- COMPLETELY separate from that of the ports base system.

Which is just a cache of the existing files, and can be blown away at
any time with no consequences other than a minute or two remaking
them.


   - Said database must be kept in sync with ports base system
 dependencies and other whatnots; and if they go out of sync

Which it rebuilds when it notices is out of date.  The only time I've
had problems out of it in years of using portupgrade is when I do
something like update BDB (or less often, portupgrade or ruby-bdb).
Whoopie.  Consider the recent case involving sudo and portmaster; when
you use a tool to update a low-level piece of itself, you have to take
some care how you go about it.


   - Said database is Berkeley DB-based, which means you have to install
 Oracle/Sleepycat BDB from ports.  (I believe you can pick DB1.x
 which comes with libc, but it's not recommended due to bugs).

So now we're up to 4 ports to install?  If you can make that my
biggest worry, I'll sent you a ginormous certified check first thing
in the morning.



There are a lot of things to hate in portupgrade, but let's don't pile
handwaving anthills into mountains on top of that.


-- 
Matthew Fuller (MF4839)   |  [EMAIL PROTECTED]
Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/
   On the Internet, nobody can hear you scream.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Upgrading the Installed package

2008-02-05 Thread navneet Upadhyay
Hi,
  I have two binary packages of an application of version 1.1 and 1.2.
*The 1.1 is already installed, how can i upgrade it to 1.2* ?

Do i have to uninstall 1.1 and then install 1.2 ?   I would prefer a way by
which i can upgrade an wxisting package without uninstalling.

Thanks,
Navneet
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]