1,105,295 Community Members

Latest Posts in Linux and Unix

Member Avatar
rubberman
Senior Poster
3,997 posts since Mar 2010
Reputation Points: 513 [?]
Q&As Helped to Solve: 501 [?]
Skill Endorsements: 87 [?]
 
0
 

@davy
This means that the mysql server package has not been installed on your system. The mysql package is just the client. The mysqld service is installed as part of the mysql-server package.

You indicate that lamp started mysql ok. That may be a red herring. Look in /etc/init.d for anything that looks like mysql...

Member Avatar
arunbohare
Newbie Poster
1 post since Apr 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

Hi I am getting the below error while launcing the sqldeveloper.
can you suggest me how to fix it.
error is -> "/opt/sqldeveloper/sqldeveloper/bin/sqldeveloper.conf to another java"

Member Avatar
CimmerianX
Practically a Master Poster
661 posts since Jul 2010
Reputation Points: 53 [?]
Q&As Helped to Solve: 83 [?]
Skill Endorsements: 13 [?]
 
1
 

As a sanity check:

dpkg -l | grep mysql

What is the output?

Member Avatar
davy_yg
Veteran Poster
1,117 posts since May 2011
Reputation Points: 0 [?]
Q&As Helped to Solve: 1 [?]
Skill Endorsements: 1 [?]
 
0
 

root@ubuntu:/opt/lampp# sudo service mysqld start
mysqld: unrecognized service

----------------------------

root@ubuntu:/opt/lampp# ./lampp startmysql
XAMPP: Starting MySQL...ok.
root@ubuntu:/opt/lampp# ./lampp status
Version: XAMPP for Linux 1.8.3-3
Apache is running.
MySQL is not running.
ProFTPD is running.

Member Avatar
endri_1
Newbie Poster
6 posts since Mar 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

thank you so much for the help

Member Avatar
JasonHippy
Practically a Posting Shark
896 posts since Jan 2009
Reputation Points: 648 [?]
Q&As Helped to Solve: 164 [?]
Skill Endorsements: 8 [?]
 
0
 

I've never really messed with vi/vim scripts, other than making a few minor modifications to my .vimrc startup file.

Using vim, you could sort the file using the command :sort.
That will sort the file in exactly the manner you have described. It's only a simple alphabetic sort, so there is no need to pass any parameters.
So you start with this:

JOHN:Morgan:90:24
MIKE:Smith:95:11
JAYSON:Ty:99:9
TYLER:Edward:89:5

Running the :sort command will give you this:

JAYSON:Ty:99:9
JOHN:Morgan:90:24
MIKE:Smith:95:11
TYLER:Edward:89:5

Which is what you wanted isn't it?

From the terminal or a shell-script, you could use the sort utility:
e.g. Sort the file and write the sorted output to a different file:
sort ./file.txt -o ./sorted.txt

But offhand, I'm not sure how you'd go about calling the sort function in a vi/vim script. I really should look into scripting vim though. I currently have a few macros set up in vim to automate various repetetive tasks. But it would be good to be able to write scripts for some of them!

Member Avatar
endri_1
Newbie Poster
6 posts since Mar 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

edited

Member Avatar
endri_1
Newbie Poster
6 posts since Mar 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

Hi eveyone. I am trying to read a file using vi editor and sort its content inside the file alphabetically which is only names on CAPITAL LETTERS, second field (JOHN, MIKE, JAYSON and TYLER).
The file is smth like this inside:
1:JOHN:Morgan:90:24
2:MIKE:Smith:95:11
3:JAYSON:Ty:99:9
4:TYLER:Edward:89:5

This is my vi script:

file="/home/students/domie/wine.txt"
while IFS=: read -r f1 f2 f3 f4 f5
do
        tput cup $f1 0 ;echo  "$f2 $f1 $f3 $f4 $f5"
done <"$file"

I came up to here to sort them, but this only switches places of f2 with f1.
Can someone help me?
thank you

Member Avatar
rubberman
Senior Poster
3,997 posts since Mar 2010
Reputation Points: 513 [?]
Q&As Helped to Solve: 501 [?]
Skill Endorsements: 87 [?]
 
0
 

You need to start the mysqld service: sudo service mysqld start

Member Avatar
davy_yg
Veteran Poster
1,117 posts since May 2011
Reputation Points: 0 [?]
Q&As Helped to Solve: 1 [?]
Skill Endorsements: 1 [?]
 
0
 

Cek this syntax:

root@ubuntu:/opt/lampp# ./lampp startmysql
XAMPP: Starting MySQL...ok.
root@ubuntu:/opt/lampp# ./lampp status
Version: XAMPP for Linux 1.8.3-3
Apache is running.
MySQL is not running.
ProFTPD is running.

I already start mysql yet it's still unable to run. Why is it?

Member Avatar
rubberman
Senior Poster
3,997 posts since Mar 2010
Reputation Points: 513 [?]
Q&As Helped to Solve: 501 [?]
Skill Endorsements: 87 [?]
 
0
 
  1. Boot to a live cd/dvd/usb drive.
  2. Do a bit copy backup of the data in /dev/sda and a separate bit copy of /dev/sda2 to another drive (an external drive would be appropriate). You use dd to copy /dev/sda, and then /dev/sda2. The bit copy of the entire drive is so if things go badly, you can restore the drive to the old image, using dd to copy the data back.
  3. Repartition with fdisk /dev/sda, removing /dev/sda1 and /dev/sda2 and then recreating /dev/sda1 to the full size of the disc. Then use the (w)rite command from fdisk to save the new configuration. Be VERY sure that the starting block of /dev/sda1 is exactly the same as it was originally.
  4. Assuming that the /dev/sda1 partition is any of ext2/3/4, then you can use the /sbin/resize2fs tool to resize the file system on /dev/sda1, expanding it to fill the new partition size.
  5. Mount the new version of /dev/sda1, loop mount the backup copy of /dev/sda2, and then copy the contents of /dev/sda2 to the new file system.
  6. Reboot.

For the bit copies, do this:

dd if=/dev/sda of=/mountpointofexternaldrive/sda bs=1M
dd if=/dev/sda2 of=/mountpointofexternaldrive/sda2 bs=1M

To resize the /dev/sda1 partition (after repartitioning the drive), do this:

/sbin/resize2fs /dev/sda1

To mount/copy the data from /dev/sda2 to /dev/sda1, do this:

mkdir /mnt/sda1 /mnt/sda2
mount /dev/sda1 /mnt/sda1
mount -o loop /mountpointofexternaldrive/sda2 /mnt/sda2
cd /mnt/sda2
cp -rfp . /mnt/sda1

BTW, you may want to save some space to create a swap partition unless you already have a swap file available.

I have used this technique myself (or variations of it) in the past. In fact I do it quite regularly on Amazon cloud systems (AWS), except there I can't boot from a live cd/dvd/usb drive. I detach the discs from one image, load them into another, and then do my work there. After that, I detach them from the work system and reattach them to the original image, reboot, and voila! One advantage of AWS is that you can easily create a snapshot of a disc image so restoring the disc if you mess up is simple.

Member Avatar
mwenyenia07
Junior Poster in Training
51 posts since Jul 2011
Reputation Points: -1 [?]
Q&As Helped to Solve: 1 [?]
Skill Endorsements: 0 [?]
 
0
 

Hi .

I have two partitions that I want to merge into one large disk. partition 1 has systems running on it while partition 2 does not have any. they are as follows:

Disk /dev/sda: 107.4 GB, 107374182400 bytes
255 heads, 63 sectors/track, 13054 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000edd29

Device Boot Start End Blocks Id System
/dev/sda1 * 1 5100 40960000 83 Linux
/dev/sda2 5100 13054 63895231 83 Linux

that is the output of fdisk -l. the disk does not have volume gropus or logical volumes. How can I merge the two without loosing data in partition 1(/dev/sda1)

Member Avatar
Mike2342
Newbie Poster
12 posts since Apr 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

Yes, it will support for prestashop version 1.6.

Member Avatar
Mike2342
Newbie Poster
12 posts since Apr 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 
Member Avatar
Mike2342
Newbie Poster
12 posts since Apr 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

Yes, then it will be great.

Member Avatar
Matthew34
Newbie Poster
10 posts since Apr 2014
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

My supplier uses mainly UPS for deliveries. Is there an option to generate UPS label or something like it.?

Member Avatar
Assembly Guy
Posting Whiz
350 posts since Apr 2013
Reputation Points: 72 [?]
Q&As Helped to Solve: 39 [?]
Skill Endorsements: 21 [?]
 
0
 

Also, remember that you cannot run 64-bit virtual machines on a 32-bit CPU

Not directly, no, but bear in mind I've been running TempleOS on my 32 bit machine using qemu-system-x86_64.

Member Avatar
m.a.u.
Light Poster
33 posts since Oct 2009
Reputation Points: 0 [?]
Q&As Helped to Solve: 0 [?]
Skill Endorsements: 0 [?]
 
0
 

Might I ask if there is a library which I could use in ethernet communication, especially for data acquisition purpose?

boost.asio is an alternative for such applications as far as I see.

If I could link in Code::Blocks, currently what I prefer to use, GnuRadio seems to be a perfect match along with its signal processing modules; already have some python, gnuradio, & numpy experience.

Socket is also another option, but never used - no idea.

Member Avatar
davy_yg
Veteran Poster
1,117 posts since May 2011
Reputation Points: 0 [?]
Q&As Helped to Solve: 1 [?]
Skill Endorsements: 1 [?]
 
0
 

I figure that one out. Now another problem:

This url: http://localhost:5080/openmeetings/ normally works in linux. but not this time, why is it?

Is it because my xampp is not on? I already try this:

davy@ubuntu:~$ sudo /opt/lampp/lampp start
[sudo] password for davy:
Starting XAMPP for Linux 1.8.3-3...
XAMPP: Starting Apache...ok.
XAMPP: Starting MySQL...ok.
XAMPP: Starting ProFTPD...ok.

-------------------------------------------

Unable to connect

Firefox can't establish a connection to the server at localhost:5080.

The site could be temporarily unavailable or too busy. Try again in a few moments.
If you are unable to load any pages, check your computer's network connection.
If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web.
Member Avatar
JasonHippy
Practically a Posting Shark
896 posts since Jan 2009
Reputation Points: 648 [?]
Q&As Helped to Solve: 164 [?]
Skill Endorsements: 8 [?]
 
0
 

No worries, glad to have helped. Mark as solved??

Linux and Unix Tag Cloud