cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2364
Views
0
Helpful
0
Replies

Making Cisco Packet Tracer operational on Fedora Linux

rickytigg
Level 1
Level 1

 Hello. It appears that Cisco Packet Tracer can also be made operational on Fedora Linux with the Debian-type installation binary file. Here is presented a methodology in this regard. In home directory, under a common directory, here named cisco, are found the resources:
- scripts uninstall.sh and install.sh
- Debian-type installation binary file for Cisco Packet Tracer

uninstall.sh

#!/bin/bash 
if [ -e /opt/pt ]; then
 echo "Cisco Packet Tracer | Uninstall."
 sudo rm -rfI /opt/pt /usr/{share/applications/cisco*-pt*.desktop,local/bin/packettracer}
 sudo xdg-desktop-menu uninstall /usr/share/applications/cisco-pt*.desktop
 sudo update-mime-database /usr/share/mime
 sudo gtk-update-icon-cache -tf /usr/share/icons/gnome
 echo -e "\n"
fi

install.sh

#!/bin/bash
# Text enhancement
Default="\033[0m"; Bold="\033[1m"; Cyan="\033[0;36m"

if [[ ! -f uninstall.sh ]]; then
 echo -e "error: file ${Cyan}uninstall.sh${Default} ${Bold}not found${Default}. It must be there where ${Cyan}install.sh${Default} is. Stopping installation process."
exit 1
else
 sh uninstall.sh
fi

# Cisco Packet Tracer installation file for Debian-type OS
file0=Cisco_Packet_Tracer_*_Ubuntu_64bit_*.deb
file1="Cisco_Packet_Tracer_<version>_Ubuntu_64bit_<10_hex_number>.deb"
CPT_path=$(find /home/$USER/cisco/ -name $file0)
echo "[Search of Cisco Packet Tracer installation file for Debian-type OS]"

if [[ -z $CPT_path ]]; then
 echo -e "error: At ${Cyan}/home/$USER/cisco${Default}, Packet Tracer installation file with original name ${Cyan}$file1${Default} ${Bold}not found${Default}. It must be where install.sh is. Stopping installation process."
exit 1
else
 echo "Cisco Packet Tracer installation file for Debian-type OS found at ${Cyan}$CPT_path${Default}."
fi

echo -e "\n[Cisco Packet Tracer installation]\nCreating directory ${Cyan}packet_tracer${Default} for the extraction of the archive's files."
mkdir packet_tracer
ar -x $CPT_path --output packet_tracer/
tar -xvf packet_tracer/control.tar.xz -C packet_tracer/
tar -xvf packet_tracer/data.tar.xz -C packet_tracer/
sudo cp -r packet_tracer/{usr,opt} /
sudo sed -i "s/packettracer/packettracer --no-sandbox args/" /usr/share/applications/cisco-pt.desktop
sudo sed -i "s/sudo xdg-mime/sudo -u $SUDO_USER xdg-mime/" ./packet_tracer/postinst
sudo sed -i "s/sudo gtk-update-icon-cache --force/sudo gtk-update-icon-cache -tf/" ./packet_tracer/postinst
sudo ./packet_tracer/postinst
sudo rm -rI packet_tracer

echo -e "\n[Package dependencies installations]"
sudo dnf -qy install qt5-qt{multimedia,webengine,networkauth,websockets,webchannel,script,location,svg,speech}

 However, as it can be noticed, replacements inside control.tar.xz's postinst script had be done –for v. 8.2.0–  in order to resolve these issues:

gtk-update-icon-cache: No theme index file.
touch: cannot touch '/root/.config/mimeapps.list': No such file or directory
/usr/bin/xdg-mime: line 873: /root/.config/mimeapps.list.new: No such file or directory

 Suggestions to improve those scripts may certainly exist. I thought that the discussion could serve as valuable source for the creation of a new technical documentation aimed to cover Cisco Packet Tracer to be used with IBM's Red Hat and Fedora OSs.
 Regards.

0 Replies 0