LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-02-2023, 09:45 AM   #1
raiikar4@gmail.com
LQ Newbie
 
Registered: Jul 2023
Posts: 2

Rep: Reputation: 0
Issue with softlink creation in Ubuntu 20.02 inside a Ubuntu docker container


I am facing issue in a docker container startup. At starup of the docker container, I want to create softlinks of about 300-400 links in root-volume which is C_drive inside a docker container. The Source of the folder is EBS-volume which is mounted as D_drive. The destination is in the root-volume(C_drive). The EBS-volume(D_drive)is full, the root-volume has enough space. At the time of starting the container which is ubuntu version 20.02 the softlinks are created. I am getting error "Out of space" while creating the softlinks. The destination folder for softlinks is root-volume, why I am getting error "Out of space". As a solution, I freed 1 MB file in the EBS-Volume, then the softlinks are getting created. Once the soft links are created I am able to copy back the 1 MB file. If the softlinks creation occupies space, why I am able to copy back the 1 MB file? Why does the softlinks creation needs space in the EBS-volume(D_drive)?

The host machine has Amazon Linux2

The command used for Soft Link creation is,
eval ln -nfs "$SOURCE/*" "$DESTINATION/" || error_notification

erro_notification is a shell function for handling and logging the error.
 
Old 07-04-2023, 04:28 AM   #2
shruggy
Senior Member
 
Registered: Mar 2020
Posts: 3,670

Rep: Reputation: Disabled
Quote:
Originally Posted by raiikar4@gmail.com View Post
eval ln -nfs "$SOURCE/*" "$DESTINATION/" || error_notification
What is the purpose of eval here? I'd rather
Code:
ln -nfs "$SOURCE/"* "$DESTINATION/"
Pay attention to the quoting of $SOURCE (I highlighted the difference).
 
Old 07-24-2023, 09:59 PM   #3
raiikar4@gmail.com
LQ Newbie
 
Registered: Jul 2023
Posts: 2

Original Poster
Rep: Reputation: 0
Its not the syntax issue, it is working fine when enough disk space is available. My query was on the disk space that is required to create sim links.
 
  


Reply



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

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



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: How to Store Docker Container Data In Docker Volumes LXer Syndicated Linux News 0 03-08-2022 12:45 AM
LXer: Technology preview: Running a container inside a container LXer Syndicated Linux News 0 03-16-2021 07:54 PM
Can Ubuntu version be upgraded inside a Docker container? VikingOy Linux - Containers 5 12-10-2016 09:41 AM
LXer: Inside the Open Container Project: How Docker plans to unite the container market LXer Syndicated Linux News 0 06-23-2015 04:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:08 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration