list of forum markup codes (and testing sandbox topic)

Forum Forums Administration Site Help list of forum markup codes (and testing sandbox topic)

  • This topic has 19 replies, 4 voices, and was last updated Nov 21-2:28 am by Robin.
Viewing 15 posts - 1 through 15 (of 20 total)
  • Author
    Posts
  • #1452
    Forum Admin
    dolphin_oracledolphin_oracle

    list of known codes and enhanced codes (note some are in the editor toolbar).

    Bold [b]{content}[/b]
    Italic [i]{content}[/i]
    Underline [u]{content}[/u]
    Strikethrough [s]{content}[/s]
    Align: Center [center]{content}[/center]
    Align: Right [right]{content}[/right]
    Align: Left [left]{content}[/left]
    Align: Justify [justify]{content}[/justify]
    Horizontal Line [hr]
    Subscript [sub]{content}[/sub]
    Superscript [sup]{content}[/sup]
    Reverse [reverse]{content}[/reverse]
    Font Size [size size="{size}"]{content}[/size]
    Font Color [color color="{color}"]{content}[/color]
    Preformatted [pre]{content}[/pre]
    Blockquote [blockquote]{content}[/blockquote]
    Border [border]{content}[/border]
    Area [area]{content}[/area]
    [area area="{title}"]{content}[/area]
    Block [div]{content}[/div]
    List: Ordered [list]{content}[/list]
    List: Ordered [ol]{content}[/ol]
    List: Unordered [ul]{content}[/ul]
    List: Item [li]{content}[/li]
    Quote [quote]{content}
    [quote quote={id}]{content}
    List of Advanced BBCodes

    URL [url]{link}[/url]
    [url url="link"]{text}[/url]
    Image [img]{image_url}[/img]
    [img img="{width}x{height}"]{image_url}[/img]
    [img width={x} height={y}]{image_url}[/img]
    YouTube Video [youtube]{id}[/youtube]
    [youtube width={x} height={y}]{id}[/youtube]
    [youtube]{url}[/youtube]
    [youtube width={x} height={y}]{url}[/youtube]
    Vimeo Video [vimeo]{id}[/vimeo]
    [vimeo width={x} height={y}]{id}[/vimeo]
    [vimeo]{url}[/vimeo]
    [vimeo width={x} height={y}]{url}[/vimeo]
    Google Search URL [google]{search}[/google]
    Note [note]{content}[/note]

    example of lists

    https://www.bbcode.org/examples/?id=12

    • This topic was modified 3 years, 5 months ago by dolphin_oracle.
    • This topic was modified 3 years, 5 months ago by dolphin_oracle.
    • This topic was modified 3 years, 4 months ago by skidoo.
    #1476
    Forum Admin
    AvatarSamK

    Testing only

    Unordered list

    • item one
    • item two

    Ordered list

    1. item one
    2. item two

    Unordered list italic

    • item one
    • item two

    Unordered list bold

    • item one
    • item two

    @dolphin_oracle
    Thanks for the list. As shown above I got the lists to work OK. Could not get the coloured text to work. Perhaps another day.

    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 4 months ago by skidoo.
    #1595
    Forum Admin
    AvatarSamK

    Testing only

    Link to SSH-Conduit Guide
    http://download.tuxfamily.org/antix/docs-antiX-17/FAQ/ssh-conduit.html

    Setting Font Size
    Attempts failed.

    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 4 months ago by skidoo.
    #1641
    Forum Admin
    AvatarSamK

    Testing only

    Setting Font Size
    Further attempts failed.

    Arrow Right

    →→

    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 4 months ago by skidoo.
    #1661
    Forum Admin
    AvatarSamK

    Testing only

    Font Size and Font Colour
    This text should be blue
    This text should be large
    This text should be larger and this text should be larger and blue

    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 5 months ago by SamK.
    • This reply was modified 3 years, 4 months ago by skidoo.
    #1682
    Forum Admin
    AvatarSamK

    Testing only
    Bold and colour text
    Both apps are designed

    #3222
    Forum Admin
    AvatarSamK

    Is it possible to have bullet points begin listing on the line immediately following the preceding text rather than placing a blank line between the text and the first bullet point?

    The basic idea is to make it more obvious the bullet points are related to the preceding text.

    #3755
    Member
    Avatarskidoo

    shoes:
    •left shoe
    • right shoe

    Above, the first item is preceded by •
    and (a slightly different variation) the second item is preceded by • and a space character.

    Other htmlentities which can be useful for bulleting:
    “middot”
    ·
    ·

    “nabla”

    ∇

    “Delta” (the capital D is necessary, afaik)
    Δ
    Δ

    “rarr” (also “larr”, “uarr”, “darr” for leftarrow, right, downarrow)

    →

    “hearts”

    ♥

    “diams”

    ♦

    #3875
    Forum Admin
    AvatarSamK

    That is useful to know.

    #3946
    Member
    Avatarskidoo

    test: posting source list content triggers spamblock?

    Repos: Active apt sources in file: /etc/apt/sources.list.d/antix.list
    deb http://repo.antixlinux.com/stretch/ stretch main nosystemd

    Active apt sources in file: /etc/apt/sources.list.d/debian-stable-updates.list
    deb http://ftp.de.debian.org/debian/ stretch-updates main contrib non-free

    Active apt sources in file: /etc/apt/sources.list.d/debian.list
    deb http://ftp.de.debian.org/debian/ stretch main contrib non-free
    deb http://security.debian.org/ stretch/updates main contrib non-free

    No, at least not when the post is submitted by role:moderator

    test: same as above, wrapped in CODE /CODE (using the “code” button)

    
        Repos: Active apt sources in file: /etc/apt/sources.list.d/antix.list
        deb http://repo.antixlinux.com/stretch/ stretch main nosystemd
    
        Active apt sources in file: /etc/apt/sources.list.d/debian-stable-updates.list
        deb http://ftp.de.debian.org/debian/ stretch-updates main contrib non-free
    
        Active apt sources in file: /etc/apt/sources.list.d/debian.list
        deb http://ftp.de.debian.org/debian/ stretch main contrib non-free
        deb http://security.debian.org/ stretch/updates main contrib non-free

    No, at least not when the post is submitted by role:moderator

    test: same, wrapped in QUOTE /QUOTE (select text and click the “b-quote”)

    Repos: Active apt sources in file: /etc/apt/sources.list.d/antix.list
    deb http://repo.antixlinux.com/stretch/ stretch main nosystemd

    Active apt sources in file: /etc/apt/sources.list.d/debian-stable-updates.list
    deb http://ftp.de.debian.org/debian/ stretch-updates main contrib non-free

    Active apt sources in file: /etc/apt/sources.list.d/debian.list
    deb http://ftp.de.debian.org/debian/ stretch main contrib non-free
    deb http://security.debian.org/ stretch/updates main contrib non-free

    stumped:
    I don’t understand what caused
    this post to trigger the spam filter.

    • This reply was modified 3 years, 3 months ago by skidoo.
    • This reply was modified 3 years, 3 months ago by skidoo.
    • This reply was modified 3 years, 3 months ago by skidoo.
    #45249
    Member
    AvatarRobin

    Test
    some part of a guidance for beginners I just wrote and tried to submit causes a 403 repeatedly:

    A potentially unsafe operation has been detected in your request to this site
    Your access to this service has been limited. (HTTP response code 403)

    I am posting from antiX 17.4.1 using firefox 78.4.1esr-1~deb9u1. Don’t see where an “unsafe operation” should come from.
    Already disconnected and reconnected from internet in order to get a new IP just in case somebody to whom the first IP was assigned to just before me has done some mischief. Didn’t help.

    So I’ll now cut the text in parts, post them here separately first to figure out which part causes the blocking.
    —-starts form here—

    I just want to share my experiences for the benefit of other antiX users who might want to pursue a similar strategy.
    The text is written for the real beginner, step by step and as detailed as possible, so the old-timer might feel a little impatient and bored while reading. But I’m sure he could amend some improvements of the workflow in the end.

    As I’ve stated elsewhere here in the forum, my final goal is to have the antiX system installed on the hdd of my notebook.
    But what about the old, well oiled and fine tuned system installed on it? I prefer to keep it, since there are many helper programs installed, which I’ll probably won’t notice missing before I need one of them again, which then isn’t installed on the antiX system yet and then I couldn’t remember its name, which causes me researching for some hours again.
    Moreover there are some homebrew shellscripts for solving dedicated problems stored on it, which I also don’t remember exactly what and where, but if I need one, I’ll know: It has bin there and there.
    From past times I remember, when dd-ing the complete hdd or partition two things will happen:
    The resulting partition-images are not really handy, they need to be cut into parts, compressed to fit on
    a couple of DVD and I’ll probably never again have the diskspace to recreate and re-open them when I’d like to
    search them for a script or program I perfectly know I’ve had at hand for a special task in the old system.
    The second thing to happen is: Taking the before said into account, I will litter them, after having stored
    them for years without having any way to make use of them.
    So this time I decided to manage things the another way around:
    I want to move the complete existing system from hdd to an usb-stick, keeping it bootable and usable, just as antiX runs now from the stick. The roles will be changed after that. antiX will boot form hdd, and the old system will boot from the stick.

    I’ll repartition the hdd to current needs (it’s still partitioned as historically grown by succesively installing
    different operating systems, which means: a couple of pretty small partitions, in a crude order spread over the hdd. I’d prefer to make a clean cut and from now on use GPT instead of MBR, which should be possible even when this notebook does only provide BIOS, (no EFI). Then I’ll create one small (2 GiB) Boot partition, one 12GiB for / (root), one swap (4GB) and all the remaining space will be used for the /home partition. I’ll try to use Extlinux instead of grub now, the isolinux/syslinux bootprocess on antiX-live/persist has ben convincing. And after these preliminaries I’ll finally install antiX in the newly created hdd structure. That is the line of approach.

    Back to the first step:
    Exporting the complete system to a memory stick. Sounds easy, but there are some pitfalls. Sounds difficult on the other hand, but it isn’t really.

    First I had to prepare the USB-memory-stick. It is a cheap standard 64GB USB2/3 type, preformated for use on Windows-systems. I’ll give a step by step explanation of the complete process just in case someone wants to undertake the same procedure before installing antiX.

    (make sure to use the fastest USB your PC provides. Some older models have USB 1.x and 2.0 both, and using the 1.0 only will slow things realy down. Everything from 2.0 should be ok, but it works even with 1.0, if you have no choice. You can check with lsusb as described below.)

    Boot from antiX live-USB-Stick (or from CD/DVD). Don’t use a frugal install for this since it uses the hdd, possibly partitions you need to be untouched (unchanged) during the process.

    Open a terminal (Menu–>Terminal), type “sudo su” and give your sudoer-password. (As you probably know, since it can be found in the antiX manuals, the standard PW for a non-persistent live system is “demo”.) Keep this terminal open until we’ve finished. Some people prefere to prefix every single command they key in with “sudo”. You can do it that way as well, omit simply the line “sudo su” and set sudo in front of each command instead.
    hint:
    – the “#” shows that you are in the role of “root” in that very moment, the command you key in is executed with root privileges.
    – the “$” denotes that you are in simple user context and the commands are executed with the restricted privileges of the actual user.

    You’ll always find these marks in the terminal somewhere at the beginning of the commandline.
    Don’t key in these signs, only the commands behind them.

     
            sudo su
    	demo		<--- sudoer pw in antiX live, key in when asked.
    	# lsusb
    	# lsblk
    

    Example Output of lsusb and lsblk (before pluging in new stick):

    #45250
    Member
    AvatarRobin

    Test:

    Example Output of lsusb and lsblk (before pluging in new stick):

    
    # lsusb
    Bus 001 Device 003: ID 090c:2000 Silicon Motion, Inc. - Taiwan			<--after knowing which bus is capable of USB2.0 we can see antiX live stick is pluged in one of the proper slots already.
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub   <--here we have the USB2.0 Hub, look for which bus-Number it has
    Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 002 Device 002: ID 093a:2533 Pixart Imaging, Inc.              <--this is an USB-mouse only, at one of the USB1.1 plugs.
    Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    # lsblk
    NAME    MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
    loop0     7:0    0  2,6G  1 loop /live/linux	  <- these two loop-entrys belong to the antiX live system.
    loop1     7:1    0  1,5G  0 loop /home					it is *not* your home-partition on your hdd, it contains antiX user "demo".
    sda       8:0    0 93,2G  0 disk 				  <--here starts the hdd
    ├─sda1    8:1    0    8G  0 part /media/_daten1	  <--this is the primary partition, originally used by another OS, nowadays used as file-storage
    ├─sda2    8:2    0    1K  0 part 				  <--this is the extended partition (look at its size)
    ├─sda5    8:5    0   20G  0 part /media/_home	  <--this is the first logical partition within the extended partition
    ├─sda6    8:6    0   10G  0 part /media/_daten2	  <--another partition previously used by an even older OS , now file-storage
    ├─sda7    8:7    0 42,5G  0 part /media/_daten3   <--this was preveously the home-partition of that even older OS, now file-storage
    ├─sda8    8:8    0    3G  0 part /media/_daten4   <--another historically grown partition now in use as file-storage. 
    ├─sda9    8:9    0  2,2G  0 part [SWAP]			  <--this is the swap-partition of the old ubuntu system
    └─sda10   8:10   0  7,5G  0 part /media/sda10	  <--this is actually the root partition of the old ubuntu system.
    sdb       8:16   1 29,5G  0 disk 					<--here starts the USB stick with antiX on it, even if it is named "disk" here.
    ├─sdb1    8:17   1 29,5G  0 part /live/boot-dev		<--this is one of its partitions
    └─sdb2    8:18   1   50M  0 part /media/antiX-uefi	<--and that is the other one.
    sr0      11:0    1 1024M  0 rom  					<--finally we have a cd/dvd-drive.
    

    This PC has as well 1.x as 2.0 USB conectors, you’ll have to look for the desciption at the end of the line for the word “2.0 root hub” (or evern higher) and then at the beginning of that line where is written the bus number, in this example it is bus 001. Now look for what else is connected to that very bus number. In this case there is a Bus001 Device 003, which is the Live antix USB stick. On one of the USB 1.1 plugs you can see the mouse (Bus 002, Device 002)

    The partition order and usage is a little confused, since it is historicaly grown 😉 Never mind, it’ll work anyway, since the partitions used for file-storage don’t need to be transfered to the stick. They’ll get stored elewhere later on to free up the harddrive completely, which is a really easy job. The concern for today is to move the existing OS to a stick from within antiX live and make it bootable at its new residence.

    Plug in the fresh USB-Stick. key in again:

    
    	# lsusb
    	# lsblk
    

    Example output (after pluging new stick):

    
    #lsusb
    Bus 001 Device 003: ID 090c:2000 Silicon Motion, Inc. - Taiwan
    Bus 001 Device 004: ID 058f:6387 Alcor Micro Corp. Flash Drive	<--the new USB-stick, connected also to USB2.0 capable slot.
    Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
    Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    Bus 002 Device 002: ID 093a:2533 Pixart Imaging, Inc. 
    Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
    #lsblk
    NAME    MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
    loop0     7:0    0  2,6G  1 loop /live/linux
    loop1     7:1    0  1,5G  0 loop /home
    sda       8:0    0 93,2G  0 disk 
    ├─sda1    8:1    0    8G  0 part /media/_daten1
    ├─sda2    8:2    0    1K  0 part 
    ├─sda5    8:5    0   20G  0 part /media/_home
    ├─sda6    8:6    0   10G  0 part /media/antiX
    ├─sda7    8:7    0 42,5G  0 part /media/_daten3
    ├─sda8    8:8    0    3G  0 part /media/_daten4
    ├─sda9    8:9    0  2,2G  0 part [SWAP]
    └─sda10   8:10   0  7,5G  0 part /media/sda10
    sdb       8:16   1 29,5G  0 disk 
    ├─sdb1    8:17   1 29,5G  0 part /live/boot-dev
    └─sdb2    8:18   1   50M  0 part /media/antiX-uefi
    sdc       8:32   1 58,6G  0 disk 									<--here we are!
    └─sdc1    8:33   1 58,6G  0 part /media/sdc1-usb-Generic_Flash_Di	<--and this is the (empty) partition the manufacturer has put on it.
    sr0      11:0    1 1024M  0 rom  
    

    After pluging the new stick to an USB-connector, it should be also located at bus 001, since we know by now this is the one which provides USB2.0 in this case. If not, try another plug and restart this procedure.
    The Plugs aren’t to distingusih optically from outside. You’ll have to adapt the concept to what you will find at your PC, maybe you even find USB3.0

    Compare the output of the first with the second lsblk command. The enty which hasn’t been present there before is the devicename of the USB-stick. You can clearly see the new device sdc in the example output, which refers to the drive as a whole, and the device sdc1 which is the partition, it has only one in this case, otherwise there would be entrys like sdc2 sdc3 and so on. These new entries are what we are looking for.
    Write down:

    #45251
    Member
    AvatarRobin

    Test

    Write down:

    /dev/sdc (for sdc, the drive) and
    /dev/sdc1 (for sdc1, the partition).

    (This is an example from my setup only, you’ll have to write down what you get from your own screen).

    These are the folders in your system where the programs can find that very drive and partition(s).
    It is absolutely important to be sure about which device you want to adress later, since any mistake in these names will probably result in complete erasing another drive unwantingly! Don’t plug off or on anything before having gone through the following procedure completely, hence this might change these names in your system with all conseqences.

    Now start from the antiX main menue the program “gparted”:
    Menu–>Programs–>Systemtools
    (or just type in the root console window “gparted&”, the ampersand is not a typo! it lets you work on at the console while the program is still running.)

    At the upper right corner of gparted program window choose the “Drive” you just have found.
    +++ WATCH OUT: A fault in choosing the correct drive here will delete your data without return!

    – remove all the partitions on that drive (and only on that one)
    – start the execution, wait until it is done.

    Maybe you get a warning, the partitions were just in use, since they probably have been mounted automatically while plugging on the stick
    In this case you’ll have to unmount before proceeding: Key in your root terminal window from above:

    	
    # umount /dev/sdc1
    

    or just let it be done by the drive-unmounter from the antiX taskbar. Now the deletion of the partition should complete without complaints.

    Next in the gparted window create new Partitions, according to your old system on the hdd:
    1.) 1x Primary, ext 4, Name: “/”, Size as required, but bigger (or at least same size) than that partition containig the root-filesystem on your hdd, in my case this was 7,5GiB, I’ve chosen 10GiB which is 10240MiB (gparted asks for MiB)
    2.) 1x Extended (size: all the rest of the Drive)
    3.) 1x Logical, within the Extended one. ext4 also, named “/home”. Size may take the complete remains of the drive, as you like. At least it must have the size of the /home partition of your old system on hdd.
    (at this point you’ll have to add more logical partitions if your old system you want to transfer requires them, name them as they are named in the old system. You can
    get the correct names by keying in “blkid” in the still opened root-terminal from above.)
    (Swap partition will not be created on this SDD, one can create this later, but there will be probably be always a swap partition on your hdd you can use, so you don’t really need one on the thumbdrive.)
    If you’d like to make the system on the thumbdrive running a little faster, just read this concerning a correct allignment of your new partitions:
    (Partition Alignment detailed explanation)
    But it will work anyway, even without a correct alignment. Moreover I’m nearly sure gparted in the antiX version I’ve been using would manage this in the correct way automatically for you.

    – start the execution, wait until is done.

    – Set the Flag “boot” on primary partition.

    Close the program gparted, as we don’t need it anymore, but let the root-console window still open.

    The freshly partitioned stick possible won’t be readable in your old system, even if it has EXT4 drives itself. Crude thing this, but true. This is true, if the kernel of your hdd-system is older than the one on the antiX you are just working with. You can’t determine whether it’ll be readable (and bootable in consequence) by your old system, since Ext4
    names itself always Ext4, instead of Ext4.01 Ext4.02 and so on, even if the versions are not backward compatible. So it can happen an Ext4 formatted USB-stick is unreadable in another PC, which understands Ext4 also, only cause of an even slightly older kernel version it still has.
    So you’ll have to do some aditional steps:
    In case you don’t know the version number of the old kernel by heart and don’t want to boot it up right now just for reading it out, you can look at its root partition:

    Key in into the still open root console window

    
    	# dumpe2fs /dev/sdc1 |grep "Filesystem features:"
    

    the result should look something like

    
    		dumpe2fs 1.43.4 (31-Jan-2017)
    		Filesystem features:      has_journal ext_attr resize_inode dir_index filetype needs_recovery extent 64bit flex_bg sparse_super large_file huge_file metadata_csum uninit_bg dir_nlink extra_isize
    

    This output will show you which features are actually active on the Ext4 filesystem just created on the stick.
    Now we’ll have to compare it with the capabilities of the Ext4 filesystem provided by your old system

    Mount your root partition of hdd, in my case it was /dev/sda10 to a place you like or let antiX mounter script do it for you.
    I mounted it to /media/sda10, so I had to key in for
    looking into the grub config file:

    
    		# cat /media/sda10/boot/grub/grub.cfg |grep "menuentry"
    			menuentry 'Ubuntu, with Linux 3.2.0-126-generic' --class ubuntu --class gnu-linux --class gnu --class os {
    

    or read the names of the subfolders in the folder:

    
    		# ls /media/sda10/lib/modules
    			3.2.0-125-generic  3.2.0-126-generic
    

    In any case counts the highest version number which is present there.

    You will find for each feature in the output from dump2fs above an entry in the list provided in
    Ext4 Kernel Support
    and you should look carefully, if there is a feature in your Ext4 filesystem active which has been implemented only in a kernelversion higer than that you have found for the OS you want to transfer to the stick.
    If you find all the features supported by the Ext4 provided by your old system everything is fine, you don’t have to do the following steps and can directly go ahead to the file transfer below.

    But if not, as it was in my case, you’ll have to deactivate the features of the filesystem on the stick which are not supported. In my case it was a feature called “metadata_csum” which was the culprit, it is in Ext4 not before kernel version 3.18 and ubuntu didn’t provide a new kernel since 3.2.0-126 for the lts-system on that notebook.
    So if we want to have the old system boot from the stick, we’ll have to make it suitable for the old kernel.
    (Alternatively you could have done all the steps before from within your old system, but there was in my case no gparted installed, and you won’t get it installed these days anymore from the repos. They are not existant anymore at ubuntu servers.)
    Another way around would be to homebrew a new kernel from source, at least 3.18 (cause of metadata_csum) for the old system, which doesn’t make any sense in my opinion, for the system gets conserved for backup purposes only. So I’ll stick to what I can get.
    So, to make things short, key in the still open root console window:

    
    	# tune2fs -O +uninit_bg /dev/sdc1
    	# tune2fs -O +uninit_bg /dev/sdc5
    	# tune2fs -O ^metadata_csum /dev/sdc1
    	# tune2fs -O ^metadata_csum /dev/sdc5
    

    (for details about what you are doing: $ man tune2fs in another console window)

    #45252
    Member
    AvatarRobin

    Test

    (for details about what you are doing: $ man tune2fs in another console window)
    in short:
    -O (great “O”ven, to confuse with “Zero” or small “o”) means set/unset Options
    the “^” in front of the feature deactivates it
    a “+” in front of it activates it.
    (I have activated aditionally uninit_bg, since I found it activated on every ext4 filesystem created by my old OS, and it only speeds up the checkup of the filesystem)
    The activated 64bit option should be no problem since it is implemented since kernel 2.6.28, even if it was not active in other ext4 filesystems created under the old OS.

    It might be possible, that you get asked by tune2fs to execute

    
    	# e2fsck 
    

    in order to check the filesystem after switching features on or off. So just do it when requested.

    Now we are ready to transfer the old system from the HDD to the stick.

    Since we’ll need the UUID of our new partitions in the process we should write them down for later use:
    the primary partition is /dev/sdc1, which will become our boot and root partition,
    the first logical partititon in the extended is /dev/sda5 (a rule which is true in most cases for linux systems)
    this will be our new /home partition.

    
    	# dumpe2fs /dev/sdc5 |grep "Filesystem UUID:"
    	dumpe2fs 1.43.4 (31-Jan-2017)
    	Filesystem UUID:          a4489010-a7a5-4249-b88e-4702a5672450
    
    	# dumpe2fs /dev/sdc1 |grep "Filesystem UUID:"
    	dumpe2fs 1.43.4 (31-Jan-2017)
    	Filesystem UUID:          76135213-70cb-4645-862b-4725026f4727
    

    Then we have to mount the partitions we want to transfer as well as these where it has to be written on:
    For preventing accidentally writing something to the original partitions on hdd, we mount them adding the option “-o ro”, for read-only.

    
    	# mkdir /mnt/Ubuntu-root
    	# mount /dev/sda10 -o ro /mnt/Ubuntu-root
    
    	# mkdir /mnt/Ubuntu-home
    	# mount /dev/sda5 -o ro /mnt/Ubuntu-home
    
    	# mkdir /mnt/USBstick-root
    	# mount /dev/sdc1 /mnt/USBstick-root
    
    	# mkdir /mnt/USBstick-home
    	# mount /dev/sdc5 /mnt/USBstick-home
    

    (if one of the partition refuses to be mounted, execute “fuser”:
    in case e.g. /dev/sda10 won’t mount key in

    
    	# fuser -v -m /dev/sda10
    

    which will show you the culprit in most cases. Close the program which uses the device, then unmount the partition and start again with mounting it as above described.

    These preliminarys done, we will now actually start the transfer, using rsync.
    This will create a copy of the complete file- and folderstructure of the hdd-partition on the partition USB-stick.
    If you’d like to find out more about what the options mean and what they do, you’ll find them listed in ” $ man rsync” typed in a non-root console window.

    
    	# rsync --stats --progress --numeric-ids -axAhHSP  /mnt/Ubuntu-root /mnt/USBstick-root
    	# rsync --stats --progress --numeric-ids -axAhHSP  /mnt/Ubuntu-home /mnt/USBstick-home
    

    If you provide aditional the option “–quiet” it will work slightly faster, but you will not get any information about the running process.
    Keep cool, it lasts some time until everything is finally at its place…

    After that I decided to check the result:

    
    	# rsync --stats --progress --numeric-ids -axAhHSPc /mnt/Ubuntu-home/ /mnt/USBstick-home
    	# rsync --stats --progress --numeric-ids -axAhHSPc /mnt/Ubuntu-root/ /mnt/USBstick-root
    

    the aditional “c” option makes a checksum comparison, so if nothing shows up to have been changed, everything is fine now.

    #45253
    Member
    AvatarRobin

    Test

    the additional “c” option makes a checksum comparison, so if nothing shows up to have been changed, everything is fine now.

    Example output of the check, everything fine:

    
    		# rsync --stats --progress --numeric-ids -axAhHSPc /mnt/Ubuntu-root/ /mnt/USBstick-root
    		sending incremental file list
    
    		Number of files: 283,193 (reg: 183,665, dir: 26,884, link: 72,525, dev: 82, special: 37)
    		Number of created files: 0
    		Number of deleted files: 0
    		Number of regular files transferred: 0
    		Total file size: 5.97G bytes
    		Total transferred file size: 0 bytes
    		Literal data: 0 bytes
    		Matched data: 0 bytes
    		File list size: 1.24M
    		File list generation time: 0.220 seconds
    		File list transfer time: 0.000 seconds
    		Total bytes sent: 13.65M
    		Total bytes received: 29.63K
    
    		sent 13.65M bytes  received 29.63K bytes  7.98K bytes/sec
    		total size is 5.97G  speedup is 436.01
    

    At this point, everything is written on the USB-stick already.
    Now we have still to do some homework for school:
    first, we have to modify fstab on the freshly created stick according to the given facts when booting from the stick later. Since we will never guess, which /dev/sdXY the stick will get assigned at boot-time, we will switch to UUID-method to identify the partitions. In case of “/” there is the UUID of the hdd, which has to be replaced with the one of the root-partition of the stick, we have written down at the beginning. Also the entry of the home partition has to be corrected: We replace the /dev/sda5 entry with the UUID of our /home partition of the stick. Moreover we have to replace ext3 by ext4, since we have an ext4 filesystem now.

    
    # cat /mnt/Speichertift-root/etc/fstab
    		# /etc/fstab: static file system information.
    		#
    		# Use 'blkid -o value -s UUID' to print the universally unique identifier
    		# for a device; this may be used with UUID= as a more robust way to name
    		# devices that works even if disks are added and removed. See fstab(5).
    		#
    		# <file system>                            <mount point>   <type>  <options>             <dump>  <pass>
    		proc                                        /proc           proc    nodev,noexec,nosuid   0       0
    		#
    		# / was on /dev/sda10 during installation
    		#UUID=0eb91a9b-ea52-4f5b-9140-5a06f6f73d1d  /               ext4    errors=remount-ro     0       1
    		# moved to new location
    		UUID=76135213-70cb-4645-862b-4725026f4727   /               ext4    errors=remount-ro     0       1
    		#
    		#
    		# swap was on /dev/sda11 during installation
    		# UUID=dbb40875-198e-4fd7-b6e4-e59ee464426b none            swap    sw                    0       0
    		# existing swap on /dev/sda9
    		UUID=2d151628-e6f1-4e23-a8a6-7820d17b8a14   none            swap    sw                    0       0
    		#
    		#
    		# existing home on /dev/sda5 94021be3-c160-4166-a151-92ad72b26f9a
    		#/dev/sda5 /home ext3 nodev,nosuid 0 2
    		# moved to new location, using ext4 now
    		UUID=a4489010-a7a5-4249-b88e-4702a5672450   /home           ext4    rw,nodev,nosuid       0       2
    #
    

    In the fstab file all the lines beginning with a sharp sign (#) are comments and will be ignored by the system. In this case they contain earlier entrys and comments some of which were created during original installation of the OS by the installer-script. Here are alle the new UUIDs at its place already.
    You can edit this file with a graphical text-editor (e.g. geany from antiX menu), but you’ll need root privileges to write it back to the stick after having done all amendments.
    So you might key in into the still open root console window

    
    			# geany&
    

    btw, you don’t need to care about the tons of spaces between the entrys on a single line, they are for human readability only. It merely has to be at least 1 Space between them.

    And here comes the feestyle skate, after having done all the duty:

Viewing 15 posts - 1 through 15 (of 20 total)
  • You must be logged in to reply to this topic.