最近遇到一台装有Fedora Core 5.0 Linux操作系统的服务器,原来安装的Apache 2.0、PHP 5.1.2不支持GD库,PHP网页中用GD库生成的验证码图片、统计图都无法显示。我试过在此基础上安装php-gd-5.1.2-5.i386.rpm包后还是不行。于是,想到了先卸载已安装PHP的所有RPM包,再重装PHP的方法。于是动手尝试,问题解决。
  
  一、在/var目录下新建一个临时目录php,将Fedora Core 5.0第2~5张光盘RPM目录中,以“php-”开头的RPM文件复制到/var/php目录中;
  
  二、在终端中执行以下命令(红字部分):
  1、查看已安装的PHP有哪些RPM包:
  [root@smis ~]# rpm -qa|grep php
  php-pear-1.4.6-2
  php-5.1.2-5
  php-gd-5.1.2-5
  php-ldap-5.1.2-5
  
  2、卸载用上述命令查看后列出的RPM包:
  [root@smis ~]# rpm -e php-pear-1.4.6-2 php-5.1.2-5 php-gd-5.1.2-5 php-ldap-5.1.2-5
  
  3、进入/var/php目录:
  [root@smis ~]# cd /var/php
  
  4、列出/var/php目录下的文件:
  [root@smis php]# ls
  php-5.1.2-5.i386.rpm           php-ncurses-5.1.2-5.i386.rpm
  php-bcmath-5.1.2-5.i386.rpm    php-odbc-5.1.2-5.i386.rpm
  php-dba-5.1.2-5.i386.rpm       php-pdo-5.1.2-5.i386.rpm
  php-devel-5.1.2-5.i386.rpm     php-pear-1.4.6-2.noarch.rpm
  php-gd-5.1.2-5.i386.rpm        php-pgsql-5.1.2-5.i386.rpm
  php-imap-5.1.2-5.i386.rpm      php-snmp-5.1.2-5.i386.rpm
  php-ldap-5.1.2-5.i386.rpm      php-soap-5.1.2-5.i386.rpm
  php-mbstring-5.1.2-5.i386.rpm  php-xml-5.1.2-5.i386.rpm
  php-mysql-5.1.2-5.i386.rpm     php-xmlrpc-5.1.2-5.i386.rpm
  
  5、安装你需要的组件的RPM包:
  [root@smis php]# rpm -ivh php-5.1.2-5.i386.rpm php-ncurses-5.1.2-5.i386.rpm php-bcmath-5.1.2-5.i386.rpm php-odbc-5.1.2-5.i386.rpm php-dba-5.1.2-5.i386.rpm php-pdo-5.1.2-5.i386.rpm php-devel-5.1.2-5.i386.rpm php-pear-1.4.6-2.noarch.rpm php-gd-5.1.2-5.i386.rpm php-pgsql-5.1.2-5.i386.rpm php-snmp-5.1.2-5.i386.rpm php-ldap-5.1.2-5.i386.rpm php-soap-5.1.2-5.i386.rpm php-mbstring-5.1.2-5.i386.rpm php-xml-5.1.2-5.i386.rpm php-mysql-5.1.2-5.i386.rpm php-xmlrpc-5.1.2-5.i386.rpm
  warning: php-5.1.2-5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 4f2a6fd2
  Preparing...                ########################################### [100%]
     1:php                    ########################################### [  6%]
     2:php-pdo                ########################################### [ 12%]
     3:php-ncurses            ########################################### [ 18%]
     4:php-bcmath             ########################################### [ 24%]
     5:php-odbc               ########################################### [ 29%]
     6:php-dba                ########################################### [ 35%]
     7:php-devel              ########################################### [ 41%]
     8:php-pear               ########################################### [ 47%]
     9:php-gd                 ########################################### [ 53%]
    10:php-pgsql              ########################################### [ 59%]
    11:php-snmp               ########################################### [ 65%]
    12:php-ldap               ########################################### [ 71%]
    13:php-soap               ########################################### [ 76%]
    14:php-mbstring           ########################################### [ 82%]
    15:php-xml                ########################################### [ 88%]
    16:php-mysql              ########################################### [ 94%]
    17:php-xmlrpc             ########################################### [100%]
  
  6、重新启动Apache服务:
  [root@smis php]# service httpd restart
  停止 httpd:                                               [确定]
  启动 httpd:                                               [确定]
  
  7、完毕。


Tags: ,
技术大类 » PHP/JS/Shell | 评论(35) | 引用(0) | 阅读(39786)
xujie777 Email
2012-5-18 14:51
coach outlet has become a popular shopping experience for consumers around the world, and a desirable distribution channel for manufacturer's and retailers.Getting your hands on coach outlet store online can be a hefty investment of hundreds of dollars.But do not despair,the Coach Outlet store could be the answer to your prayers.coach outlet online is your smart choice when you want to get the discount Coach accessory. You can find the exact Coach Bags and other accessory you want at a low price that's right for you. My dear friends, let the coach outlet online pave your way into the world of high fashion with their ultimate fashion factory.
xujie222
2012-5-21 10:40
Our online store offers you discounted Designer louis vuitton replica wallet at present. You could find them in desirable quality and price. If you don't mind high class louis vuitton uk, have a good time here.louis vuitton Store Online Handbags can also bring great accuracy as well as practical applicability and fashionable.Have you ever dreamed of being as charming as Madonna? Have you ever thought of becoming an envy of all your friends? If so, come to louis vuitton outlet.<br/>
xujie555
2012-5-21 13:07
coach factory outlet uses graceful accessories to match the classical logo of coach, which is the best combination of coach. The handmade coach products?can make you more charming and graceful.coach factory online provides people many coach goods. If you wish to snatch the coach handbag, then this best method is made for that you like for coach discount.coach factory outlet online is a fashion brand to ensure its quality. With designer coach shoulder bags, you will always attract people's attention. The bags will emphasize your personal style and taste.<br/>
xujie333
2012-5-21 14:27
coach outlet online Store guarantee that all the coach handbags offered are own high quality. In addition , all of them are sold at an unexpected low price.If you want to purchase, just visit their website.coach factory outlet is really sizzling kinds of shopping way for you. With the usage of the replica designer coach bags, you can surely be able to change your individual looks in a stunning manner.Coach bags on sale from the coach outlet are cheap or discount prices that you certainly will stand out from the crowd on your next camping trip!<br/>
Bottega Veneta Wallet Email Homepage
2012-8-7 01:18
Leaping rope works major muscle groups which include shoulders arms legs and abdominals and burns a lot of calories Coach Factory
coach88888888 Email
2012-8-13 17:11
Coach Factory Outlet can design new and original products that are also functional. The stylish appearance of products, sophisticated workmanship, superior quality and highly competitive prices have won the customer's trust and love from consumers at home and abroad. So you can rest assured that purchase.Coach Factory Online are loved by many people, when you walk in the street, you could see many people take coach styles.And Coach Outlet Online is a great gift because there are many different styles that could be coordinated with different personalities together.If your dream is to look like a million bucks for a mere several dollars, then our Coach Outlet store is the Jiminy Cricket of your existence.
Coach Factory Email Homepage
2012-8-20 03:17
These ones with clover vamps accept covering lining and leather-covered cream in linings Coach Handbags
songzhang567 Email Homepage
2012-8-20 10:11
Smith says e US is into an election year and while some may anticipate this is a reason for US travellers to stay home,14947,Michael Kors Sale,1152, there is no hard evidence to substantiate this If copying direct from the source put quotation marks on it to evade plagiarism
songzhang567 Email Homepage
2012-8-20 10:12
Jack Simony has also made himself involved with different organizations such as the w York Athletic Club?and my and Navy Club? thus helping us know the interests of this famous businessmanAnabolic steroidhormones worked so good that they became wide spread among base ballplayers like Lyle Alzado,Michael Kors Outlet,4740, Barry Bonds and others to sprinters BenJohnson and Marion Jones as well as basketball players and footballstars,Michael Kors Outlet Online,19729, MMA fighters etc
Louis Vuitton Purses For Cheap Email Homepage
2012-8-31 12:47
******abaft their aberrant reactions if she or he see a birkin backpack Louis Vuitton Purses For Sale
cheap north face jackets Email Homepage
2012-11-9 10:06
Waterproof, breathable, cheap north face jackets seam sealed north face jackets are lightweight with durable quality and delivers outstanding performance in the cold, whether sprinting round the block or heading out into the hills. Contrasting color logo is cheap north face jackets for men screen-printed on the chest, the stylish north face jackets are best selling at great price, realistic
HAWER
2013-1-29 17:25
买轴承就到:www.jkzhoucheng.cn
lanctly Email
2013-4-24 15:40
WizToner.com is a professional Toner Cartridge Manufacturer and Toner Cartridge Supplier in china, offering the fine quality Toner Cartridge Manufacturer & Remanufactured and excellent service to our clients.
Cheap Printer Cartridge Australia Homepage
2017-8-31 07:29
Look for cheapest printer cartridges online? Cheap Inks is your one stop printer consumables shop. Cheap ink cartridges compatible for Brother, Canon, Epson, HP, Lexmark. Cheap toner cartridges compatible for Xerox, Samsung, Brother, OKI, Kyocera and Minolta. Save printing cost is easy. Buy discount printer consumables with us today!today!www.cheapinks.com.au
Cheap Printer Cartridge Australia Homepage
2017-8-31 07:29
[url=http://cheapinks.com.au]
分页: 2/2 第一页 上页 1 2 最后页
发表评论
表情
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
打开HTML
打开UBB
打开表情
隐藏
记住我
昵称   密码   游客无需密码
网址   电邮   [注册]